Overview
Thefastskill init command creates a skill-project.toml file for skill authors. This command extracts metadata from an existing SKILL.md file (if present) and interactively prompts for any missing information to create a properly configured skill project.
This command is for skill authors who want to create a new skill project. It generates the
skill-project.toml manifest file that defines your skill’s metadata, dependencies, and configuration. For general FastSkill setup, see the Installation Guide.Context Detection:
fastskill init automatically detects whether you’re working in a skill directory or project root:- Skill-level: If run in a directory containing
SKILL.md, createsskill-project.tomlwith[metadata]section (for skill authors) - Project-level: If run at project root, can create
skill-project.tomlwith[dependencies]section (for skill consumers)
What It Does
When you runfastskill init, it performs the following steps:
- Checks for Existing Files: Validates if
skill-project.tomlalready exists - Reads SKILL.md: Extracts metadata from frontmatter (name, description, version, etc.)
- Interactive Prompts: Asks for missing information or uses provided CLI arguments
- Creates skill-project.toml: Generates the manifest file with proper structure
- Validates Configuration: Ensures all required fields are present and valid
Usage
Interactive Setup (Recommended)
Non-Interactive Setup
Command Options
| Option | Description | Default |
|---|---|---|
--yes | Skip interactive prompts, use defaults | false |
--force | Reinitialize even if files exist | false |
--skills-dir <DIR> | Skills directory path | .skills |
--embedding-model <MODEL> | OpenAI embedding model | text-embedding-3-small |
--no-example | Skip creating example skill | false |
Files Created
.fastskill/config.yaml
Service-level configuration file with your embedding settings:
.fastskill/config.yaml. Project-level configuration (skill dependencies and repositories) is stored in skill-project.toml at your project root.
.skills/ Directory Structure
Example Skill
Creates a basic skill at.skills/examples/hello-world/SKILL.md:
Configuration Options
Embedding Models
| Model | Description | Cost | Use Case |
|---|---|---|---|
text-embedding-3-small | Cost-effective, good performance | Low | Most projects |
text-embedding-3-large | Higher accuracy, more expensive | High | Enterprise, high-precision needs |
| Custom | Any OpenAI-compatible model | Varies | Advanced users |
Skills Directory
- Default:
.skills(recommended) - Custom: Any directory path you specify
- Existing: Will be created if it doesn’t exist
Environment Variables
OPENAI_API_KEY
The init command will use this environment variable if set:Troubleshooting
”API key should start with ‘sk-’”
Cause: The provided API key doesn’t match OpenAI’s format Solution: Check that you’re using a valid OpenAI API key”API key appears to be too short”
Cause: The API key is incomplete Solution: Ensure you’re copying the complete API key from OpenAI”FastSkill is already initialized”
Cause: Configuration files already exist Solution: Use--force to reinitialize, or remove existing files first
Permission Denied
Cause: Cannot write to the current directory Solution: Check file permissions or run in a directory where you have write accessIntegration with CI/CD
For automated setups in CI/CD pipelines:Best Practices
Project Structure
Keep FastSkill configuration at the project root:API Key Management
- Development: Use environment variables
- Production: Use secure secret management
- CI/CD: Store in encrypted secrets
Version Control
Consider what to commit:Next Steps After Init
- Add Your Skills: Create skill directories under
.skills/ - Index Skills: Run
fastskill reindexto build the search index - Test Search: Try
fastskill search "your query" - Integration: Connect to your AI agent or application