Chalk home page
Docs
API
CLI
  1. Getting Started
  2. Configuration Files

Overview

Your Chalk project’s configuration is shared across the following files:

  1. chalk.yaml (or chalk.yml): Configuration for your project’s deployment
  2. .chalkignore: Files to exclude from your project’s deployment
  3. requirements.txt: Default Python requirements for Chalk to install via pip (can be overridden in chalk.yaml)

Here’s our recommended repository structure:

company_chalk/
├── src/
│  ├── resolvers/
│  │  ├── .../
│  │  ├── __init__.py
│  │  └── pipelines.py
│  ├── __init__.py
│  ├── datasources.py
│  └── feature_sets.py
├── tests/
│  └── ...
├── notebooks/
│  └── ...
├── .chalkignore
├── chalk.yaml
├── README.md
└── requirements.txt

chalk.yaml

Use chalk.yaml to configure your project’s Docker environment, Python configuration, and metadata validation for your features and resolvers.

Schema

chalk.yaml
projectstr
The name of this Chalk project, which must match your project's name in the dashboard (case-sensitive).
environmentsdictionary
Per-environment overrides. See our Docker documentation for more details.
[environment_name]dictionary
The name of this environment, such as prod or qa. Find available environment names in your dashboard. Use default to configure default values to apply to all of this project's environments.
runtime"python310" | "python311"
The Python version for the Chalk project.
requirementsstr
Python requirements file to install with pip.
dockerfilestr
Path to an alternative Dockerfile that will be used to build a base image for your Chalk deploys.
validationdictionary
Configuration for metadata validation for features and resolvers. See our validation documentation for more details.
featuredictionary
Validations for all features.
metadatalist
A list of dictionaries of metadata attributes and error severity levels when this metadata property is missing.
name"description" | "owner" | "tags"
The name of the metadata property.
missing"info" | "warning" | "error"
The level of severity to use when a feature is missing this metadata property. Deploys are permitted forinfo and warning levels, but disallowed for `error` level.
resolverdictionary
Validations for all resolvers.
metadatalist
A list of dictionaries of metadata attributes and error severity levels when this metadata property is missing.
name"description" | "owner" | "tags"
The name of the metadata property.
missing"info" | "warning" | "error"
The level of severity to use when a feature is missing this metadata property. Deploys are permitted forinfo and warning levels, but disallowed for `error` level.

Sample file

Here is a sample chalk.yaml file. In this file, we use a different Dockerfile in production.

project: my-project-id

environments:
  default:
    runtimes: python310
    requirements: requirements.txt
  prod:
    dockerfile: ./DockerfileProd

validation:
  feature:
    metadata:
      - name: owner
        missing: error
      - name: description
        missing: warning
      - name: tags
        missing: info
  resolver:
    metadata:
      - name: owner
        missing: error

.chalkignore

Your .chalkignore file should include your scripts, notebooks, and tests. Anything that you are not actively using in your deployment should be added so that non-deployment code does not clutter or interfere with your deployment.

requirements.txt

By default, Chalk will use pip to install Python requirements from ./requirements.txt in your project’s root directory. You may override this file’s location within the environments dictionary of your chalk.yaml file.