Skip to content

skilld self - generate a live skill from the current project #33

@oritwoen

Description

@oritwoen

skilld currently generates skills from npm dependencies, but the project you're actually working in has no skill of its own. skilld self would index the current repo's source, docs, and structure into a self-referencing skill that stays fresh as the codebase changes.

The core idea is simple: treat cwd as the "package" and run the same chunking/embedding pipeline over local files instead of fetching from npm/GitHub. The skill would live in the same agent skill dir as dependency skills, so agents pick it up automatically.

What this would need:

  • Scan local files - reuse the existing glob patterns from detect-imports (**/*.{ts,js,vue,...}) but index the content itself, not just the import graph. README, docs folders, and source files all go into the search index.
  • File watcher - skilld self --watch monitors the project and incrementally updates the index when files change. This ties directly into Search index rebuild is all-or-nothing - no incremental updates #28 (incremental index updates) since the watcher needs upsert/delete on individual documents rather than full rebuilds.
  • SKILL.md generation - a base SKILL.md describing the project (from package.json name/description, directory structure, key entry points). Could optionally run through the LLM for richer context.
  • Separate storage - the self-skill index should probably live in .skilld/self/ or similar, not in the global ~/.skilld/references/ cache (this isn't a versioned package, it's a living workspace).

The watcher is the interesting part. Without it, skilld self is just a one-shot indexer that goes stale the moment you edit a file. With it, agents always search against up-to-date project context, which makes skilld search useful for "how does this project handle X" questions during development.

Implementation could start without the watcher (one-shot skilld self that indexes once) and add --watch later once #28 lands the incremental indexing infrastructure.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions