importing-a-codebase
Skill by JetBrains
Creates an initial spec graph for an existing codebase that has source code but no specs. It reverse-engineers the specs the project should have had, for developers working in a repo without specs.
Install importing-a-codebase
Built from the published package, never by AI.
git clone --depth 1 https://github.com/JetBrains/thinkrail /tmp/thinkrail && mkdir -p ~/.claude/skills && cp -r /tmp/thinkrail/packages/pi-thinkrail-workflow/skills/importing-a-codebase ~/.claude/skills/importing-a-codebaseRun in your terminal. Claude Code loads skills from ~/.claude/skills automatically.
git clone --depth 1 https://github.com/JetBrains/thinkrail /tmp/thinkrail && mkdir -p ~/.gemini/antigravity-cli/skills && cp -r /tmp/thinkrail/packages/pi-thinkrail-workflow/skills/importing-a-codebase ~/.gemini/antigravity-cli/skills/importing-a-codebaseAntigravity CLI loads skills from ~/.gemini/antigravity-cli/skills, or .agents/skills for one project.
Step-by-step: install importing-a-codebase in Antigravity CLI
Skills can run scripts on your machine. Some need an API key: check the README.
About
This skill turns an existing codebase with no specs into a draft spec graph. It reads agent files, READMEs, docs, manifests and entry points first, then collects existing design docs, ADRs and glossaries as candidates to adopt. It forms a working model of the project's purpose, modules, invariants and decisions, and asks the user only about gaps the files cannot answer.
The skill drafts a goal-and-requirements node, an architecture node and one short module spec per real module, saved with the spec tools. Inferred content is marked unconfirmed until the user reviews it. The skill is meant for un-specced repositories and is normally reached through the setting-up-a-project dispatcher.
Written from the project's SKILL.md and checked against it.
What it can do
- Survey the repositoryReads agent files, docs, manifests, layout and entry points before asking any questions.
- Collect adoption candidatesFinds durable design docs, ADRs, glossaries and contract docs that can become spec nodes in place.
- Build a working modelForms a summary of the project's purpose, domain, stack, modules, invariants and decisions.
- Interview the gapsAsks only the questions the code cannot answer, in rounds, with inferred options for the user to correct.
- Draft the spec graphCreates goal, architecture and module spec nodes top-down with the spec tools.
- Validate and hand offRuns spec validation and summarizes what was inferred, adopted and corrected for user review.
What you need
- Spec tools (spec_grep, spec_graph, spec_create, spec_validate)
- The writing-specs concept skill
- The asking-user-questions concept skill
Try asking
- Import this codebase and create the initial spec graph for it
- Survey this repo and propose which existing docs should become specs
- Draft architecture and module specs for this project from its code
Good to know
- Only for codebases that have source code but no specs yet
- Inferred content stays draft and unconfirmed until the user reviews it
- Nothing merges until the user approves the drafted specs in Changes
- Later features and behavior changes are handed off to brainstorming
Security check
ANo download-and-run commands, hidden instructions or signs of sending keys out were found.
Checked automatically: packages/pi-thinkrail-workflow/skills/importing-a-codebase/SKILL.md. This looks for known risky patterns and is not a full audit. How grades work
Inside the skill
-
SKILL.md7 KB
Alternatives to importing-a-codebase
All alternatives →Runs a 7-stage workflow for auditing, cleaning up and reviewing GitHub repositories, plus competitor analysis. Written for developers who want a repo checked for secrets, junk files and documentation gaps.
Teaches an AI assistant to build, debug and explain Gradio web UIs and ML demos in Python. It covers the core API, components, event listeners, layouts and the MCP server option. Aimed at Python developers who work with Gradio.
Recommends menus, buttons, toolbars and disclosure controls for Apple platforms using Human Interface Guidelines conventions. Built for developers and designers making iOS, iPadOS, macOS or visionOS interfaces. Checks existing project design context before asking questions.
Creates production-ready FastAPI project structures with async patterns, dependency injection, and error handling. It is for developers starting new FastAPI applications or backend API projects.
Analyzes Android apps to find user workflows to expose as AppFunctions, so AI agents and system shortcuts can run them without opening the app UI. Generates Kotlin code and refines KDoc for Android developers.
Creates, edits, validates and runs Agent QA tests, suites and hooks through MCP or CLI. It keeps canonical IDs and schema contracts intact, for developers and QA teams using Agent QA.
Compare with openclaw-github-repo-commander, gradio or hig-components-menus
importing-a-codebase: common questions
When should I use importing-a-codebase?
Use it when a repository has real source code but no specs. If specs already exist, the skill hands back to the setting-up-a-project dispatcher.
Does it change my existing documentation?
Accepted adoption candidates get spec frontmatter added in place with their content left untouched. Unclear or drifted content can be corrected during adoption, and the correction is called out.
Will it merge the specs automatically?
No. The drafted specs stay on the workspace branch for review in Changes, and nothing merges until the user approves them.
How do I install importing-a-codebase?
Run the command above to copy the skill into ~/.claude/skills/. Claude Code picks it up automatically.
Is importing-a-codebase free?
The code is published under the Apache-2.0 licence. The service it connects to may have its own pricing.
Is importing-a-codebase safe to use?
It scores 87 of 100. Grades: maintenance A, licence A, quality A. Security check: grade A, no risky patterns found in the files checked. Review the code before you install. How grades work.
What are alternatives to importing-a-codebase?
Similar skills: openclaw-github-repo-commander, gradio, hig-components-menus, fastapi-templates.
