Cog architecture and cross-cutting review guidelines
56
63%
Does it follow best practices?
Run evals on this skill
Adds up to 20 points to the overall score
View guide
Passed
No findings from the security scan
Fix and improve this skill with Tessl
tessl review fix ./.opencode/skills/cog-review/SKILL.mdCog packages ML models into production-ready containers. Use this skill for changes that cross language boundaries or touch core architecture.
cmd/cog/ and pkg/ -- builds, runs, and deploys modelspython/cog/ -- predictor interface, types, HTTP/queue servercrates/ -- prediction server inside containers (HTTP, worker management, IPC)Wheel resolution: The CLI discovers SDK and coglet wheels from dist/ at
Docker build time. Wheels are NOT embedded in the binary. Changes to build
artifacts need to account for this.
Dockerfile generation: pkg/dockerfile/ generates Dockerfiles from cog.yaml
config. Template injection and escaping matter here.
Config parsing: pkg/config/config.go parses cog.yaml. Schema is at
pkg/config/data/config_schema_v1.0.json. Changes must keep schema and Go
code in sync.
Two-process coglet: Parent process (HTTP server + orchestrator) and child worker process (Python predictor execution) communicate via IPC. Changes to the IPC protocol affect both Rust and Python code.
Compatibility matrix: CUDA/PyTorch/TensorFlow compatibility is managed in
tools/compatgen/. Framework version changes have wide blast radius.
Cargo.toml must match.python/cog/base_predictor.py affect all downstream model authors.docs/ require running mise run docs:llm to regenerate docs/llms.txt.cmd/ or pkg/cli/ require mise run docs:cli.integration-tests/ use Go's testscript and need a built cog binary.4e62b8b
If you maintain this skill, you can claim it as your own. Once claimed, you can manage eval scenarios, bundle related skills, attach documentation or rules, and ensure cross-agent compatibility.