Skip to content

feat(skills): ship use-ig (Praxis-MCP read variant) at login#60

Merged
anshulsao merged 3 commits into
mainfrom
feat/ship-use-ig-mcp
Jul 15, 2026
Merged

feat(skills): ship use-ig (Praxis-MCP read variant) at login#60
anshulsao merged 3 commits into
mainfrom
feat/ship-use-ig-mcp

Conversation

@anshulsao

@anshulsao anshulsao commented Jul 15, 2026

Copy link
Copy Markdown
Contributor

What

Ships use-ig as a binary-embedded tree meta-skill, installed at praxis login.
This is the Praxis-MCP read variant of ig's use-ig skill: catalog reads run
server-side via praxis mcp ig (ig_impact/ig_query/ig_explain/
ig_list_catalogs), so the host needs no ig binary for reads. Only setup +
CI still need ig + graphify locally.

Counterpart to infragraphify#40: ig skills install now ships the native
(local-ig) use-ig only when praxis is absent; when praxis is present, it installs
this MCP copy. Same skill name (use-ig) — exactly one exists at a time.

Server side already landed in agent-factory (the ig gateway MCP:
praxis mcp ig …).

Changes

  • internal/skillinstall/embedded/use-ig/SKILL.md — MCP-route skill: graph
    mental-model + gotchas + recipes carried over from the canonical native skill,
    invocation surface swapped to praxis mcp ig ig_* --arg catalog= --arg target=.
    No local ig/$IG_HOME/praxis ig sync in the read path.
  • internal/skillinstall/embedded.go — embed both trees; generalize treeSkills()
    over a treeSkillNames slice. MetaSkillNames/IsMetaSkill/login-install/
    profile-switch preservation pick up use-ig with no further change.

Testing (TDD)

internal/skillinstall/embedded_test.go +3: MetaSkillNames includes use-ig
(sorted), IsMetaSkill("use-ig") preserved, and an MCP-variant guard (SKILL.md
has name: use-ig + praxis mcp ig, and NOT the local-ig ig query command).
go build, go vet, gofmt, go test ./... all clean/green.

Sequencing

Pairs with infragraphify#40; both gate on agent-factory's praxis mcp ig being
deployed so the skill's commands actually answer.

🤖 Generated with Claude Code

Summary by CodeRabbit

  • New Features
    • Added the use-ig skill for querying prebuilt catalogs and exploring service relationships (including frontend-to-backend routing and impact).
    • Updated built-in skill packaging so multiple embedded tree skills are bundled and discovered together.
  • Documentation
    • Added a full use-ig guide covering the catalog model, available ig_* tools, common workflows, and practical caveats.
  • Bug Fixes
    • Improved coverage and safeguards to ensure use-ig stays correctly recognized across profile switches and routes through praxis mcp ig (not the native local ig read flow).

Add a second binary-embedded tree skill, `use-ig`, that praxis installs
during `praxis login`. It is the Praxis-MCP READ variant of ig's native
use-ig skill: the graph query mental-model (catalog / members /
interface-nodes / calls|deploys_as|provisions edges) and the worked
examples (FE->BE trace, blast-radius/impact, where-does-X-live) are
preserved, but the whole invocation surface is swapped to the server-side
`praxis mcp ig` tools (ig_list_catalogs / ig_explain / ig_impact /
ig_query), so the host needs no local `ig` binary, no synced tree, and no
cloud secrets. Same bare name as ig's native skill — only one is ever
installed at a time (ig ships its native copy only when praxis is absent).

Wiring:
- Generalize the tree-skill embed: rename onboardingTreeFiles ->
  treeSkillFiles, embed both embedded/praxis-onboarding and
  embedded/use-ig, and drive treeSkills() off a treeSkillNames slice.
  MetaSkillNames()/IsMetaSkill() therefore pick up use-ig with no further
  change, so login installs it and profile switches preserve it.

Tests (TDD, RED->GREEN):
- MetaSkillNames() includes "use-ig" (and stays sorted).
- IsMetaSkill("use-ig") is true (survives profile switch).
- treeSkillFS("use-ig") SKILL.md has `name: use-ig`, invokes reads via
  `praxis mcp ig`, and carries no local-`ig` read command surface
  (guards this is the MCP variant, not the native one).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@coderabbitai

coderabbitai Bot commented Jul 15, 2026

Copy link
Copy Markdown

Review Change Stack

Walkthrough

The PR embeds multiple tree skills, adds the use-ig skill documentation, and tests its registration, profile behavior, embedded content, and MCP routing guidance.

Changes

Embedded use-ig skill

Layer / File(s) Summary
Embed multiple tree skills
internal/skillinstall/embedded.go
The embedded filesystem now includes praxis-onboarding and use-ig, with per-skill filesystem lookup and skill-specific missing-skill errors.
Document ig catalog workflows
internal/skillinstall/embedded/use-ig/SKILL.md
The new skill documents praxis mcp ig commands, catalog and graph concepts, traversal recipes, limitations, and a worked example.
Validate use-ig registration and content
internal/skillinstall/embedded_test.go
Tests verify sorted registration, profile-independent meta-skill recognition, and required embedded use-ig content.
🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly summarizes the main change: adding and installing the use-ig Praxis-MCP read skill at login.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feat/ship-use-ig-mcp

Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 2

🧹 Nitpick comments (1)
internal/skillinstall/embedded/use-ig/SKILL.md (1)

32-32: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick win

Add language identifiers to the fenced blocks.

markdownlint-cli2 reports MD040 for these four fences. Use text for the graph diagram and console or text for command examples.

Also applies to: 45-45, 85-85, 148-148

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@internal/skillinstall/embedded/use-ig/SKILL.md` at line 32, Add explicit
language identifiers to all four fenced code blocks in SKILL.md to satisfy
MD040: use text for the graph diagram and console or text for the command
examples. Update only the affected fences, including those around the referenced
sections.

Source: Linters/SAST tools

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@internal/skillinstall/embedded_test.go`:
- Around line 63-71: Update the embedded skill validation test around the
existing praxis mcp ig assertions to use a table-driven list containing
ig_list_catalogs, ig_explain, ig_impact, and ig_query, and explicitly assert
each command appears in body. Retain the existing check preventing the native
`ig query` command surface.

In `@internal/skillinstall/embedded/use-ig/SKILL.md`:
- Around line 30-37: Update the catalog/target requirement guidance around
ig_list_catalogs to explicitly identify it as the argument-free discovery
exception, and state that only the remaining three tools require catalog and
target arguments. Keep the existing discovery command and subsequent
catalog-selection instructions unchanged.

---

Nitpick comments:
In `@internal/skillinstall/embedded/use-ig/SKILL.md`:
- Line 32: Add explicit language identifiers to all four fenced code blocks in
SKILL.md to satisfy MD040: use text for the graph diagram and console or text
for the command examples. Update only the affected fences, including those
around the referenced sections.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 2807f494-c870-41c0-ada3-31bf8b8c8dae

📥 Commits

Reviewing files that changed from the base of the PR and between d729ec1 and 4519899.

📒 Files selected for processing (3)
  • internal/skillinstall/embedded.go
  • internal/skillinstall/embedded/use-ig/SKILL.md
  • internal/skillinstall/embedded_test.go

Comment on lines +63 to +71
// Reads must route through the Praxis MCP.
if !strings.Contains(body, "praxis mcp ig") {
t.Errorf("use-ig SKILL.md must invoke reads via `praxis mcp ig` (MCP variant)")
}
// It must NOT carry the native local-`ig` read command surface. The
// backticked `ig query` is the tell of the local-ig variant; this MCP
// copy uses `praxis mcp ig ig_query` instead.
if strings.Contains(body, "`ig query`") {
t.Errorf("use-ig SKILL.md contains local-ig read command `ig query`; this must be the `praxis mcp ig` variant")

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win

Assert every required MCP tool explicitly.

Checking only for the generic praxis mcp ig prefix would still pass if one of the required tools were removed from the skill. Assert all four commands: ig_list_catalogs, ig_explain, ig_impact, and ig_query.

As per coding guidelines, use a table-driven test for the required tool list.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@internal/skillinstall/embedded_test.go` around lines 63 - 71, Update the
embedded skill validation test around the existing praxis mcp ig assertions to
use a table-driven list containing ig_list_catalogs, ig_explain, ig_impact, and
ig_query, and explicitly assert each command appears in body. Retain the
existing check preventing the native `ig query` command surface.

Source: Coding guidelines

Comment thread internal/skillinstall/embedded/use-ig/SKILL.md Outdated
…kill

The ig read verbs address a node per member (`ig <verb> <member> <target>`), and
the server-side MCP now requires `--arg member=<m>`. The skill was written for a
single `--arg target=<node>`, so an agent following it would hit "member is
required" on every read call.

Teach `member` as a lens into the graph of graphs:
  * member=catalog -> interface/connection layer (service:/route:/graph: nodes +
    cross-repo calls/deploys_as/provisions edges) — where "how repos connect" lives
  * member=<repo>  -> that repo's code graph
  * member=infra   -> the Facets infra graph

Updates the command surface, list-catalogs (now returns members), recipes, the
worked example, and adds a "wrong member = no node" gotcha. Mirrors the
already-correct 2-positional model in infragraphify's native use-ig skill.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@internal/skillinstall/embedded/use-ig/SKILL.md`:
- Around line 119-147: Update every ig_explain and ig_query invocation in the
documented recipes to include the required selected catalog argument in the form
--arg catalog=<c>. Preserve each command’s existing member and target arguments
while applying this consistently across all examples.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 6f4877b4-019a-4b7f-9b82-d299d6ee8615

📥 Commits

Reviewing files that changed from the base of the PR and between 4519899 and 71b1c3e.

📒 Files selected for processing (1)
  • internal/skillinstall/embedded/use-ig/SKILL.md

Comment thread internal/skillinstall/embedded/use-ig/SKILL.md Outdated
…_path, ig_catalog

The server-side ig MCP grew to full raw-ig read parity (agent-factory), so teach
the six tools instead of four:
  * ig_query now takes FREE TEXT via `--arg query="..."` (was a node `target`),
    has NO depth (ig hardcodes query depth), and takes `--arg relation=` /
    `--arg context=` edge filters + `--arg budget=`.
  * ig_impact gains the same relation/context filters (+ real depth).
  * new ig_catalog (`--arg catalog=<c>`) — the topology map; START HERE for
    "how do these connect".
  * new ig_path (`--arg from_node=<a> --arg to_node=<b>`) — shortest path.

Updates the command surface, the boundary line (four → six), and the recipes
(connect-map via ig_catalog, A→B via ig_path, free-text query=).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@internal/skillinstall/embedded/use-ig/SKILL.md`:
- Line 103: Update the fenced code block in SKILL.md to specify the shell
language by changing its opening fence to ```sh, while preserving the block’s
existing shell commands and closing fence.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: b8e3b5c8-ae09-49b5-8905-052c39687741

📥 Commits

Reviewing files that changed from the base of the PR and between 71b1c3e and f8b3a70.

📒 Files selected for processing (1)
  • internal/skillinstall/embedded/use-ig/SKILL.md

`ig_list_catalogs`/`ig_catalog`, `--arg member=<m>` (the lens — see above).
Output is **token-budgeted TEXT** written for an LLM to read.

```

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

📐 Maintainability & Code Quality | 🟡 Minor | ⚡ Quick win

Specify the fenced block language.

Markdownlint reports MD040 here. Since the block contains shell commands, use ```sh instead of an untyped fence.

Proposed fix
-```
+```sh
🧰 Tools
🪛 markdownlint-cli2 (0.23.0)

[warning] 103-103: Fenced code blocks should have a language specified

(MD040, fenced-code-language)

🪛 SkillSpector (2.3.11)

[warning] 66: [MP2] Context Window Stuffing: Skill attempts to fill the context window with filler content, displacing legitimate instructions and safety constraints. This can degrade agent performance or bypass safety boundaries.

Remediation: Implement context-window management that detects and rejects padding or stuffing attempts. Prioritize system instructions over user-injected content.

(Memory Poisoning (MP2))

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@internal/skillinstall/embedded/use-ig/SKILL.md` at line 103, Update the
fenced code block in SKILL.md to specify the shell language by changing its
opening fence to ```sh, while preserving the block’s existing shell commands and
closing fence.

Source: Linters/SAST tools

@anshulsao
anshulsao merged commit 68ebe0b into main Jul 15, 2026
3 checks passed
@anshulsao
anshulsao deleted the feat/ship-use-ig-mcp branch July 15, 2026 08:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant