Skip to content

feat: CLI formatters + response types + debug gating#48

Merged
PatrickSys merged 5 commits intomasterfrom
feat/cli-formatters
Feb 28, 2026
Merged

feat: CLI formatters + response types + debug gating#48
PatrickSys merged 5 commits intomasterfrom
feat/cli-formatters

Conversation

@PatrickSys
Copy link
Owner

@PatrickSys PatrickSys commented Feb 28, 2026

Summary

  • Add human-readable formatters for all CLI commands (patterns, search, refs, cycles, metadata, style-guide) — --json flag outputs raw JSON
  • Add MetadataDependency interface and fix MetadataInner.dependencies type (string[]MetadataDependency[])
  • Fix metadata formatter displaying [object Object] for dependencies
  • Fix search confidence clamped to 1.00 (RRF scores can exceed 1.0)
  • Fix refs preview lines truncated with ellipsis instead of wrapping (which lost indentation)
  • Gate debug noise behind CODEBASE_CONTEXT_DEBUG env var (search, transformers, lancedb)
  • Add cli-memory.ts for memory CLI commands
  • Add CLI tests (tests/cli.test.ts)

Test plan

  • npm run build passes clean
  • npm test — 239/239 passing
  • metadata command shows real package names, not [object Object]
  • search --intent edit confidence shows ≤ 1.00
  • refs --symbol AuthStore preview lines truncate cleanly, no orphaned continuations
  • patterns, cycles render correctly
  • --json flag on any command outputs raw JSON

Copy link

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: c2edc2f405

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Copy link

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

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

20 files reviewed, 5 comments

Edit Code Review Agent Settings | Greptile

…opUsed

P1: tools return { status: 'error', message } without setting isError on
the MCP envelope. formatJson now detects this before routing to a command
formatter, which would otherwise render a misleading empty box.

P2: get_team_patterns --category libraries returns topUsed instead of
patterns. Add LibraryEntry type, make PatternResponse.patterns optional,
and render topUsed in formatPatterns under a TOP LIBRARIES section.
Repository owner deleted a comment from greptile-apps bot Feb 28, 2026
Repository owner deleted a comment from greptile-apps bot Feb 28, 2026
@PatrickSys PatrickSys requested review from Copilot and removed request for Copilot February 28, 2026 13:26
@PatrickSys PatrickSys merged commit 7a6cd7b into master Feb 28, 2026
3 checks passed
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