Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 7 additions & 4 deletions AGENTS.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,8 @@ These are non-negotiable. Every PR, feature, and design decision must respect th
- **Never stage/commit `.planning/**`\*\* (or any other local workflow artifacts) unless the user explicitly asks in that message.
- **Never use `gsd-tools ... commit` wrappers** in this repo. Use plain `git add <exact files>` and `git commit -m "..."`.
- **Before every commit:** run `git status --short` and confirm staged files match intent; abort if any `.planning/**` is staged.
- **Avoid using `any` Type AT ALL COSTS.
- \*\*Avoid using `any` Type AT ALL COSTS.

## Evaluation Integrity (NON-NEGOTIABLE)

These rules prevent metric gaming, overfitting, and false quality claims. Violation of these rules means the feature CANNOT ship.
Expand Down Expand Up @@ -128,6 +129,11 @@ If an agent has to call the tool twice to understand the response, the tool fail
- `src/core/` is framework-agnostic. No hardcoded framework strings (Angular, React, Vue, etc.).
- CLI code belongs in `src/cli.ts`. Never in `src/index.ts`.
- Framework analyzers self-register their own patterns (e.g., Angular computed+effect pairing belongs in the Angular analyzer, not protocol layer).
- **Types and interfaces must be framework-agnostic in core and shared utilities.**
Framework-specific field names (Angular-only, React-only, etc.) belong exclusively in their
respective analyzer files under `src/analyzers/`. Never add named framework-specific fields
to interfaces in `src/types/`, `src/utils/`, or `src/core/`.
Use `Record<string, T>` for open-ended data that frameworks extend at runtime.

### Release Checklist

Expand All @@ -153,6 +159,3 @@ These came from behavioral observation across multiple sessions. They're here so
See `internal-docs/AGENTS.md` for internal-only guidelines and context.

---

**Current focus:** See `internal-docs/ISSUES.md` for active release blockers.
For full project history and context handover, see `internal-docs/ARCHIVE/WALKTHROUGH-v1.6.1.md`.
10 changes: 10 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,16 @@
### Added

- **Definition-first ranking**: Exact-name searches now show the file that *defines* a symbol before files that use it. For example, searching `parseConfig` shows the function definition first, then callers.

### Refactored

- **Eliminated all `any` types**: 68 occurrences across 15 files now use proper TypeScript types. Replaced unsafe `Record<string, any>` with `Record<string, unknown>` and narrowed types using proper type guards. Promoted `@typescript-eslint/no-explicit-any` from `warn` to `error` to enforce strict typing.
- **Consolidated duplicate type definitions**: Single source of truth for shared types:
- `PatternTrend` canonical location in `types/index.ts` (imported by `usage-tracker.ts`)
- New `PatternCandidateBase` for shared pattern fields; `PatternCandidate extends PatternCandidateBase`; runtime adds optional internal fields
- New `UsageLocation` base for both `ImportUsage` and `SymbolUsage` (extends with `preview` field)
- `GoldenFile extends IntelligenceGoldenFile` to eliminate field duplication (`file`, `score`)
- Introduced `RuntimePatternPrimary` and `DecisionCard` types for tool-specific outputs
- **Scope headers in code snippets**: When requesting snippets (`includeSnippets: true`), each code block now starts with a comment like `// UserService.login()` so agents know where the code lives without extra file reads.
- **Edit decision card**: When searching with `intent="edit"`, `intent="refactor"`, or `intent="migrate"`, results now include a decision card telling you whether there's enough evidence to proceed safely. The card shows: whether you're ready (`ready: true/false`), what to do next if not (`nextAction`), relevant team patterns to follow, a top example file, how many callers appear in results (`impact.coverage`), and what searches would help close gaps (`whatWouldHelp`).
- **Caller coverage tracking**: The decision card shows how many of a symbol's callers are in your search results. Low coverage (less than 40% when there are lots of callers) triggers an alert so you know to search more before editing.
Expand Down
2 changes: 1 addition & 1 deletion eslint.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ export default tseslint.config(
// import plugin is handled via recommended usually, but kept simple for now
},
rules: {
'@typescript-eslint/no-explicit-any': 'warn',
'@typescript-eslint/no-explicit-any': 'error',
'@typescript-eslint/no-unused-vars': ['error', { 'argsIgnorePattern': '^_', 'varsIgnorePattern': '^_', 'caughtErrorsIgnorePattern': '^_' }],
'no-console': ['warn', { 'allow': ['warn', 'error'] }],
},
Expand Down
Loading
Loading