A command-line tool to automate the submission of ChipFoundry projects to the SFTP server and manage project results.
cf-cli is a user-friendly command-line tool for securely submitting your ChipFoundry project files to the official SFTP server and downloading project results. It automatically collects the required files, generates or updates your project configuration, uploads everything to the correct location on the server, and provides tools to view project results and reports.
Install from PyPI:
pip install chipfoundry-cli
cf --help-
Generate SSH Key (if you don't have one):
cf keygen
-
Register your key at https://chipfoundry.io/sftp-registration
-
Configure your credentials:
cf config
-
Initialize your project:
cf init
-
Upload your project:
cf push
-
Download results (when available):
cf pull
-
View tapeout report:
cf view-tapeout-report
-
Confirm final tapeout (when ready to send GDS to foundry):
cf confirm
Your project directory must contain:
gds/directory with one of the following:user_project_wrapper.gds(for digital projects)user_analog_project_wrapper.gds(for analog projects)openframe_project_wrapper.gds(for openframe projects)- Note: Both compressed (
.gz) and uncompressed (.gds) files are supported
verilog/rtl/user_defines.v(required for digital/analog).cf/project.json(optional; will be created/updated automatically)- Contains project metadata including
submission_state("Draft" or "Final")
- Contains project metadata including
Example:
my_project/
├── gds/
│ └── user_project_wrapper.gds
├── verilog/
│ └── rtl/
│ └── user_defines.v
└── .cf/
└── project.json
The CLI uses SSH key authentication for secure SFTP access:
- Default key location:
~/.ssh/chipfoundry-key(generated bycf keygen) - Alternative key: Specify with
--sftp-keyoption - SFTP username: Required and configured via
cf config
- Default server:
sftp.chipfoundry.io - Username format:
firstname-lastname(e.g.,john-doe)
cf keygen [--overwrite]- Generates a new RSA SSH key at
~/.ssh/chipfoundry-key - Displays the public key for registration
- Use
--overwriteto regenerate an existing key - Next step: Submit the public key to https://chipfoundry.io/sftp-registration
cf keyview- Displays the current ChipFoundry SSH public key
- Useful for viewing your key without generating a new one
- Shows the same registration instructions as
cf keygen
cf config- Prompts for your SFTP username and key path
- Defaults to
~/.ssh/chipfoundry-key - Only needs to be run once per user/machine
cf init [--project-root DIRECTORY]- Smart defaults: Auto-detects project name from directory and project type from GDS files
- Interactive prompts: Shows detected values in prompts for easy acceptance
- Creates
.cf/project.jsonwith project metadata - Note: GDS hash is generated during
push, notinit
cf push [OPTIONS]Options:
--project-root: Specify project directory--force-overwrite: Overwrite existing files on SFTP--dry-run: Preview what would be uploaded--sftp-username: Override configured username--sftp-key: Override configured key path
What happens:
- Collects required project files
- Auto-detects project type from GDS file
- Updates project configuration and GDS hash
- Uploads files to SFTP with progress bars
- Shows clean, informative output
GDS File Handling:
- Both compressed (
.gz) and uncompressed (.gds) files are supported - No automatic compression - files are uploaded as-is
- Only one version allowed - you cannot have both compressed and uncompressed versions of the same file
- Prefers uncompressed files when available
- Falls back to compressed files if no uncompressed version is available
cf pull [--project-name NAME]- Downloads project results from SFTP server
- Saves to
sftp-output/<project_name>/ - Automatically updates your local
.cf/project.jsonwith the pulled version - Creates the expected directory structure:
sftp-output/ └── <project_name>/ ├── config/ │ └── project.json └── consolidated_reports/ └── consolidated_report.html
cf confirm [OPTIONS]- Confirms your final tapeout by setting
submission_stateto "Final" - Uploads only the project.json to the SFTP server (not the entire project)
- Use this when you're ready to send your current GDS file to the foundry for tapeout processing
- Options:
--project-root: Specify project directory--project-name: Override project name--sftp-username: Override configured username--sftp-key: Override configured key path
Important: This command confirms that your current GDS file is ready to be sent to the foundry for tapeout. Only run this when you are completely satisfied with your design and ready for final tapeout processing. This action cannot be easily undone.
cf view-tapeout-report [--project-name NAME] [--report-path PATH]- Opens the consolidated tapeout report in your default browser
- Auto-detects project name from
.cf/project.jsonif available - Looks for report at
sftp-output/<project_name>/consolidated_reports/consolidated_report.html - Options:
--project-name: Specify project name manually--report-path: Provide direct path to HTML report file
cf status- Lists all your projects on the SFTP server
- Shows which projects have input files and/or results
- Displays project status in a clean table format
cf repo update [OPTIONS]- Updates local project files from the upstream GitHub repository
- Fetches configuration from
.cf/repo.jsonin the specified repository and branch - Downloads and overwrites local files based on the changes list in the configuration
- Saves configuration locally to
.cf/repo.jsonfor reference
Options:
--project-root: Specify project directory (defaults to current directory)--repo-owner: GitHub repository owner (default: chipfoundry)--repo-name: GitHub repository name (default: caravel_user_project)--branch: Branch name containing the repo.json file (default: main)--dry-run: Preview changes without updating files
What happens:
- Fetches
.cf/repo.jsonfrom the specified GitHub repository and branch - Downloads and saves the configuration file locally to
.cf/repo.json - Downloads and overwrites each file listed in the
changesarray - Provides detailed feedback on success/failure of each file update
Example:
# Preview what would be updated
cf repo update --dry-run
# Output:
# Files that would be updated:
# • .cf/repo.json (configuration file)
# • README.md
# • Makefile
# • openlane/Makefile
# Update files from upstream
cf repo update
# Output:
# Update results:
# ✓ Updated: .cf/repo.json
# ✓ Updated: README.md
# ✓ Updated: Makefile
# ✓ Updated: openlane/Makefile
# Successfully updated 4 file(s)
# All files updated successfully!Use cases:
- Keep your project up-to-date with upstream changes
- Apply bug fixes and improvements from the template repository
- Sync configuration changes from the upstream project
- Maintain consistency with the latest project structure
The CLI tracks your project submission state through the submission_state field in project.json:
-
"Draft" - Initial state when you run
cf init- Project is ready for development and testing
- You can push updates multiple times
- Project is not yet ready for tapeout processing
-
"Final" - Confirmed state when you run
cf confirm- GDS file is ready to be sent to the foundry for tapeout
- No further changes should be made to the design
- Only the project.json is uploaded (not the full project)
-
Development Phase:
cf init # Creates project with submission_state: "Draft" cf push # Upload project files (state remains "Draft") # ... make changes to your project ... cf push # Upload updated files (state remains "Draft")
-
Review Phase (Optional):
cf pull # Download results for review (if available) cf view-tapeout-report # Review the tapeout report (if available)
-
Final Tapeout Confirmation:
cf confirm # Confirm current GDS file is ready for foundry tapeout
Important: Only run cf confirm when you are completely satisfied with your GDS file and ready to send it to the foundry for tapeout processing. This action cannot be easily undone.
- The
user_project_wrapper_hashin.cf/project.jsonis automatically generated and updated duringpush - The hash is calculated from the actual GDS file being uploaded
- This ensures the hash always matches the file you are submitting
- You do not need to manage or update the hash manually
- The hash is NOT generated during
initbecause the GDS file may not exist or may change before submission
-
File Collection:
- Checks for required GDS and Verilog files
- Auto-detects project type (digital, analog, openframe) based on GDS file name
- Supports both compressed and uncompressed GDS files
-
Configuration:
- Creates or updates
.cf/project.json - Updates the GDS hash and any CLI-overridden fields
- Creates or updates
-
SFTP Upload:
- Connects to the SFTP server securely
- Creates project directory structure
- Uploads files with progress indicators
- Shows clean, minimal output
-
Success:
- Displays confirmation with project location
-
Connection:
- Connects to SFTP server securely
- Shows clean connection status
-
Download:
- Downloads all project results recursively
- Shows professional download progress
- Saves to
sftp-output/<project_name>/
-
Config Update:
- Automatically updates your local
.cf/project.jsonwith the pulled version - No manual steps required
- Automatically updates your local
-
Success:
- Shows confirmation of downloaded files and updated config
# Generate SSH key and register it
cf keygen
# Copy the displayed key to https://chipfoundry.io/sftp-registration
# Configure your account
cf config
# Enter: john-doe
# Enter: (press Enter for default key)
# Initialize project (in your project directory)
cf init
# Project name (detected: my_awesome_project):
# Project type (digital/analog/openframe) (detected: digital):
# Upload your project
cf push
# Connecting to sftp.chipfoundry.io...
# Uploading project.json ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 100%
# Uploading user_project_wrapper.gds ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 100%
# ✓ Uploaded to incoming/projects/my_awesome_project
# Later, download results
cf pull
# ✓ Connected to sftp.chipfoundry.io
# Downloading project results from outgoing/results/my_awesome_project...
# ✓ All files downloaded to sftp-output/my_awesome_project
# ✓ Project config automatically updated
# Review the tapeout report (if available)
cf view-tapeout-report
# ✓ Opened tapeout report in browser: sftp-output/my_awesome_project/consolidated_reports/consolidated_report.html
# When ready, confirm final tapeout (sends GDS to foundry)
cf confirm
# ✓ Updated project.json with submission_state = Final
# ✓ Confirmed project submission: my_awesome_project
# ✓ Uploaded project.json to incoming/projects/my_awesome_project/.cf/project.json# Preview what would be uploaded
cf push --dry-run
# Force overwrite existing files
cf push --force-overwrite
# Use different project root
cf push --project-root /path/to/project
# Pull results for specific project
cf pull --project-name other_project
# View report for specific project
cf view-tapeout-report --project-name other_project
# Confirm final tapeout for specific project
cf confirm --project-name other_project
# View custom report file
cf view-tapeout-report --report-path /path/to/custom_report.html
# Check project status
cf status# Uncompressed GDS file (preferred)
gds/user_project_wrapper.gds
# Compressed GDS file (also supported)
gds/user_project_wrapper.gds.gz
# ❌ INVALID: Both files exist - this will cause an error
gds/user_project_wrapper.gds # ← Choose ONE version only
gds/user_project_wrapper.gds.gz # ← Remove this one-
Missing files:
- The tool will error out if required files are missing or if more than one GDS type is present
-
Authentication errors:
- Run
cf keygento generate a new key - Ensure your key is registered at https://chipfoundry.io/sftp-registration
- Check your username with
cf config
- Run
-
SFTP errors:
- Check your network connection
- Verify your credentials with
cf config
-
Project type detection:
- Only one of the recognized GDS files should be present in your
gds/directory - Both compressed and uncompressed versions of the same type are supported
- Important: You cannot have both compressed (
.gz) and uncompressed (.gds) versions of the same file - the tool will error out and ask you to remove one
- Only one of the recognized GDS files should be present in your
-
Report viewing errors:
- Ensure you've run
cf pullfirst to download the report - Check that the report exists at the expected location
- Use
--report-pathto specify a custom report location
- Ensure you've run
-
Repository update errors:
- Check your internet connection
- Verify the repository and branch exist
- Use
--dry-runto preview changes before applying them - Check that the
.cf/repo.jsonfile exists in the upstream repository
-
ModuleNotFoundError:
- Upgrade the CLI:
pip install --upgrade chipfoundry-cli
- Upgrade the CLI:
- For help, contact info@chipfoundry.io or visit chipfoundry.io
- For bug reports or feature requests, open an issue on GitHub