CI runs `pnpm install` from the repo root using the root lockfile with
the default frozen-lockfile behaviour. The previous commits ran install
only inside understand-anything-plugin/ so the new
@understand-anything/tree-sitter-dart-wasm workspace dependency was
recorded in understand-anything-plugin/pnpm-lock.yaml but missed at
the repo root — CI would have stopped at install.
Flagged by @chatgpt-codex-connector on #435.
Wires Kotlin into the existing tree-sitter pipeline so .kt and .kts
files now produce functions, classes, data classes, sealed classes,
interfaces, objects, imports, exports, and call-graph edges — matching
the behavior of the other language extractors.
## Why @tree-sitter-grammars/tree-sitter-kotlin
The standard `tree-sitter-kotlin` (v0.3.8) ships only native bindings.
The new `@tree-sitter-grammars/tree-sitter-kotlin@1.1.0` ships a
prebuilt `.wasm` (loads cleanly with `web-tree-sitter@^0.26.6`,
nodeTypeCount=289, parses class_declaration / function_declaration as
expected). Same shape that PR1 used for Swift, just a different
publisher because the repomix WASM bundle does not include Kotlin.
`@tree-sitter-grammars` is the official tree-sitter org's GitHub
account, so this is the canonical upstream WASM source for Kotlin.
## Notes for reviewers
- `kotlinConfig` already existed as a stub (no `treeSitter` field), so
Android / JVM / Gradle codebases currently produce no structural
edges between `.kt` files. This PR adds the `treeSitter` field; the
existing plugin loader picks it up unchanged.
- **Visibility rule differs from Swift**: Kotlin's default visibility
is `public`, so the extractor treats *every* declaration with no
modifier as exported. Only an explicit `private` opts out. `internal`
and `protected` remain exported in the project-graph sense because
they are still resolvable from other files (within the module / via
inheritance).
- `class_declaration` in tree-sitter-kotlin is overloaded for class,
data class, sealed class, and interface (distinguished by the keyword
child and `modifiers > class_modifier`). The extractor handles all
four uniformly.
- `object_declaration` is a separate node type (Kotlin singletons) —
treated as a class-like entry with its own `name` and members.
- Primary-constructor parameters marked `val` / `var` are surfaced as
class properties; plain `parameter`s without `val/var` are
constructor-only and are NOT counted as properties (matching Kotlin
semantics).
- Import handling distinguishes the three forms: plain dotted
(`import a.b.C`), wildcard (`import a.b.*` → specifier `"*"`), and
aliased (`import a.b.C as Foo` → specifier `"Foo"`).
## Verification
- `pnpm lint` clean
- `pnpm --filter @understand-anything/core build` clean
- `pnpm --filter @understand-anything/skill build` clean
- `pnpm --filter @understand-anything/core test`: **692/692** (+22 new
Kotlin tests, matching the bar set by go-extractor.test.ts /
swift-extractor.test.ts)
- `pnpm test`: 196/196 (no regressions)
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
- typescript-eslint preset: strict -> recommended for a usable first-pass
baseline (per PR discussion); ratchet up in a follow-up.
- Drop the projectService/parserOptions block. Neither `recommended` nor
`strict` is type-aware, so it was unused; removing it also avoids the
pnpm-workspace tsconfig-resolution failure mode flagged in review.
- Add Node + browser globals via the `globals` package so .mjs scripts and
the dashboard stop hitting `no-undef`.
- Expand ignores: built bundles (**/public/**), Astro generated (.astro/),
and .private/ (eval scratch). Cuts 2400+ errors in vendored output.
- Allow `_`-prefixed unused vars/args/caught errors; skip irregular
whitespace inside comments (json-parser intentionally embeds ZWSP-escaped
block-comment examples in JSDoc).
- Fix the residual 13 genuine errors: drop dead imports/vars, replace
two `as any[]` in schema.ts with `Array<Record<string, unknown>>`,
drop unused destructure in change-classifier, drop unused catch binding
in extract-structure.mjs.
- Add EOF newline to eslint.config.mjs.
- Refresh pnpm-lock.yaml.
- Add `pnpm lint` step to .github/workflows/ci.yml so the tooling
actually enforces something.
pnpm lint now exits 0 locally; 33+13 test files / 1445 tests still pass.
Code review flagged that without it as a direct dep, TypeScript would
fail to resolve types like Attributes/NodeKey from transitive
graphology-types when later tasks import them.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Previously the mapping object was recreated on every mapKindToNodeType call. Moving it to module level means it is allocated once at load time instead of once per definition node processed.
- Add pnpm-workspace.yaml to plugin distribution so workspace:* deps resolve on install
- Add devlop and hast-util-to-jsx-runtime as explicit dashboard dependencies (pnpm strict hoisting)
- Make tsconfig.json files self-contained to work outside monorepo root
- Add prepare script to auto-build core package after pnpm install
- Bump version to 1.0.2
- Remove ChatPanel and @anthropic-ai/sdk dependency (redundant with /understand-chat)
- Replace Monaco editor with styled summary code viewer
- New graph-first layout: 75% graph + 360px right sidebar
- Dark luxury aesthetic: deep blacks, gold/amber accents, DM Serif Display typography
- Add ProjectOverview component for sidebar default state
- Learn persona now shows tour panel directly in sidebar
- Add schema validation on graph load with error banner
- Defensive null checks in store for tour methods
- Agent pipeline: write intermediate results to disk instead of context
- Agent models: sonnet for simple tasks, opus for complex (no haiku)
- Prompt-engineer all 5 agent prompts and SKILL.md
- Auto-trigger /understand-dashboard after /understand completes
- Add dashboard screenshot to README
- Bump version to 1.0.1
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Move packages/{core,dashboard,skill} into understand-anything-plugin/ to
conform to the Claude Code plugin format. Add .claude-plugin/marketplace.json
for plugin discovery. Update workspace config and docs accordingly.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Render assistant messages with ReactMarkdown (headers, code blocks,
lists, bold, links, blockquotes) instead of plain whitespace-pre-wrap
- Add "Change Key" button in chat header to clear and re-enter API key
- Document the plain-text localStorage tradeoff for API key storage
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Add the @understand-anything/skill package with context-builder (search +
1-hop expansion + layer resolution), chat prompt builder, skill definition
for Claude Code, and 14 passing tests.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Replace grid-based node positioning with dagre-powered hierarchical layout
that computes positions based on edge direction (top-to-bottom). This
produces clean, readable graphs instead of the previous chaotic grid pattern.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Add SearchEngine class with fuzzy matching across node name, tags,
summary, and languageNotes fields. Supports type filtering, result
limiting, and dynamic re-indexing via updateNodes(). Uses Fuse.js
extended search with OR-token splitting for multi-word queries.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Add runtime validation of knowledge graph JSON using Zod schemas that
mirror every type in types.ts. The loadGraph function now validates
by default (opt-out via { validate: false }) and throws descriptive
errors on invalid data.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Add TreeSitterPlugin using web-tree-sitter (WASM-based) to extract
structural information from TypeScript and JavaScript files. The plugin
implements the AnalyzerPlugin interface and extracts functions, classes,
imports, exports, and call graphs via AST traversal.
Uses web-tree-sitter instead of native tree-sitter for cross-platform
compatibility (no native compilation required).
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>