Agent skill

Vero Source Python

by sunblaze-ucb in sunblaze-ucb/vero

Load BEFORE translating Python source to Lean 4. An agent skill from sunblaze-ucb/vero.

Apache-2.0Auto-check passedWriting & Content

Install Vero Source Python

skills CLI
$ npx skills add sunblaze-ucb/vero --skill vero-source-python -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install sunblaze-ucb/vero vero-source-python --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/sunblaze-ucb/vero.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.claude/skills/vero-source-python .claude/skills/vero-source-python && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
vero-source-python
GitHub stars
107
Token cost
~1.9k tokens
SKILL.md length
703 words
Files
1
Skills in repo
16
Repo updated
First seen
Licence
Apache-2.0

At a glance

Load BEFORE translating Python source to Lean 4. An agent skill from sunblaze-ucb/vero.

  • Works in 5 steps: lake build succeeds. → Every apis[] entry in manifest.json has… → Every external lib used by the source… → …
  • Tasks that involve Translation
  • SKILL.md covers Classification (vero-discover), Type mappings, External-library handling and Module / file mapping, plus 5 more sections
  • Instructions only: no scripts, shell commands, URLs or credentials in SKILL.md

What it does

Vero Source Python is an agent skill from sunblaze-ucb/vero. Load BEFORE translating Python source to Lean 4. Provides Python-specific classification rules, type mappings, stdlib-opaque modeling guidance, and patterns for mapping Python constructs into the ratified bundle paradigm (Impl/ + Spec/ + Bundle + Harness). Pair with vero-discover, vero-plan, vero-translate, vero-spec-write, and vero-python-pitfalls.

Its SKILL.md is about 1.9k tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.

It sits in Writing & Content, covering Translation. It works with Python. The licence is Apache-2.0.

When your agent uses it

  • Tasks that involve Translation

Example prompts

  • “/vero-source-python”

Requirements

  • Python 3

Workflow steps

5 steps, taken from the first numbered list in SKILL.md.

  1. lake build succeeds.
  2. Every apis[] entry in manifest.json has its abbrev + def . with a real translated reference body inside the code marker in the right Impl…
  3. Every external lib used by the source has an opaque (and optional axiom) in global_aux, with a @review human annotation.
  4. Spec/.lean files exist as scaffolds — import .Harness + module docstring + DO NOT MODIFY notice; they will be filled by spec_write.
  5. Test.lean has #guards for every doctest found in source (or @review human notes for the curator if absent).

What it can do on your machine

Read from SKILL.md and the folder at commit 0a7325d. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    No scripts in the folder and no shell commands in SKILL.md (its code samples are lean and python).

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Vero Source Python loads about 1.9k tokens when it runs. Until then it costs about 93 tokens; SKILL.md has 703 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~93
When it runs · the whole SKILL.md, loaded when a task matches
~1.9k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from sunblaze-ucb/vero at commit 0a7325d, republished under its Apache-2.0 licence (© sunblaze-ucb). 703 words, ~1,936 tokens.

Download SKILL.mdSave it as .claude/skills/vero-source-python/SKILL.md (or your agent's skills folder).
name
vero-source-python
description
Load BEFORE translating Python source to Lean 4. Provides Python-specific classification rules, type mappings, stdlib-opaque modeling guidance, and patterns for mapping Python constructs into the ratified bundle paradigm (Impl/ + Spec/ + Bundle + Harness). Pair with vero-discover, vero-plan, vero-translate, vero-spec-write, and vero-python-pitfalls.

VCG Source — Python

Python source has no built-in spec language. The python_spec workflow translates Python to Lean (this skill + vero-translate), then spec_write (separate skill) authors the specifications. This skill covers the discover → plan → translate stages.

Reference the canonical shape at reference/BankLedger/. Every emitted file mirrors that layout.

Classification (vero-discover)

Python items map to:

Python constructLean classification
top-level def or class method, no leading underscoreAPI (kind=api)
def _foo or def __fooAPI helper (kind=api_helper); not exposed in apis[] sig list
class Foo: (data)Type (structure in Lean)
class Foo: (mixin / pure-method)Type + companion API methods
module-level constantcurator decides — usually inlined in Impl, occasionally a def
docstring with >>> doctestsTest candidate — emit as #guard in Test.lean
import math, import sys, ...External lib — model as opaque (see below)

If the source repo has typing annotations, prefer them as ground truth. Without annotations, infer from usage and flag with @review human.

Type mappings

Python typeLean target
intInt (or Nat if always non-negative — verify and annotate)
boolBool
floatFloat (with @review human: floating-point semantics differ)
strString
bytesByteArray
list[T]List T
tuple[T, U]T × U
dict[K, V]AssocList K V (or Std.HashMap K V if order doesn't matter and [Hashable K] is available)
set[T]List T (with curator-given nodup-style invariant in spec_helper) — there's no canonical Set T in core Lean 4
Optional[T] / `TNone`
Iterable[T]List T (eager); flag if streaming semantics matter
user class Foostructure Foo where

External-library handling

Python's standard library and ecosystem have no Lean equivalents in many cases. Pattern:

lean
-- !benchmark @start global_aux
/-- Opaque model of `math.sqrt`. The benchmark does not constrain the
    return value beyond non-negativity; downstream specs encode the
    minimum needed (e.g., square root of n is ≤ n).

    @review human: confirm this opaque model is sufficient for the
    intended specs. -/
opaque sqrt : Int → Int

axiom sqrt_nonneg : ∀ n, 0 ≤ sqrt n  -- only if a spec actually needs it
-- !benchmark @end global_aux

Rules:

  • Always model with opaque. Never rely on Mathlib's Real.sqrt etc. — the benchmark must be self-contained on a Mathlib-free toolchain unless the curator decides otherwise.
  • axiom only when a spec demands it. Prefer opaque alone. Each axiom must be added to manifest.json::trusted_axioms (the grader's allowlist).
  • @review human annotation every external-lib model, naming the lib + the assumption being made.
  • Preferred replacements (use these only when the curator confirms they're available on the target toolchain):
    • collections.Counter → custom AssocList Key Nat-backed structure
    • functools.reduce → List.foldl
    • itertools.combinations → custom recursive helper, flag complexity
    • re (regex) → lean-regex library OR opaque + axiom; usually opaque

Module / file mapping

One Python file → one Impl module + one Spec module + one manifest entry:

src/foo.py
  ↓
<Project>/Impl/Foo.lean    -- types + APIs, with translated reference impls in code markers
<Project>/Spec/Foo.lean    -- empty until spec_write fills
manifest.json -> packages[0].modules[?] = { name=Foo, impl=..., spec=..., apis=[...] }

Multi-file Python packages (pkg/__init__.py, pkg/sub.py) flatten by moduling: <Project>/Impl/Pkg.lean, <Project>/Impl/PkgSub.lean. Document the flattening in curation/notes.md.

Translate stage shape (per file)

lean
-- File header / imports
-- !benchmark @start imports
import <Project>.Bundle
-- !benchmark @end imports

-- Module docstring (curator-written, frozen)
/-! # <Project>.Impl.<ModuleName>

<one-paragraph summary of the module's purpose, ported from the
Python module docstring + reading the source>
-/

namespace <Project>

-- Types (curator-given, frozen — no markers around individual types)
structure Foo where ...
deriving Repr, BEq

-- Sig abbrevs (one per API, listed in manifest)
abbrev BarSig := Int → Foo → Foo
abbrev BazSig := Foo → Bool

-- Opaque external models + their axioms (if needed)
-- !benchmark @start global_aux
opaque sqrt : Int → Int
-- !benchmark @end global_aux

-- APIs — one !benchmark code pair per api; body is the translated reference implementation
-- !benchmark @start code_aux def=bar
-- !benchmark @end code_aux def=bar
-- !benchmark @start code def=bar
def <Project>.bar : <Project>.BarSig :=
  -- translated Python body, not `sorry`
  ...
-- !benchmark @end code def=bar

end <Project>

API helpers (Python _foo) get the same code + code_aux marker pair but without an abbrev <Foo>Sig — manifest lists them under api_helpers[] (kind=api_helper), and validator skips the sig-abbrev requirement.

Show full SKILL.md (286 more words)Show less

Tests (Test.lean)

For every doctest in the Python source, emit a #guard:

python
def factor(n: int) -> int:
    """
    >>> factor(9)
    3
    """
    ...

→

lean
/-- doctest: factor(9) -> 3 -/
#guard <Project>.factor 9 == 3

If the Python source has no doctests, ask the curator (via @review human) what #guards to add. Do not invent expected outputs that are not grounded in the Python source, documentation, or a curator-approved oracle.

Plan stage shape

The plan emitted by vero-plan has the same shape as for Dafny/Verus/Coq — api_namespace, packages, modules, types, apis with lean_name + sig_abbrev + lean_type. The difference: specs[] may be empty (you're not mining them from source) and the ref_impls[] come from the Python translation, not a verified reference.

Verify before declaring translate done

  1. lake build succeeds.
  2. Every apis[] entry in manifest.json has its abbrev <Sig> + def <Project>.<name> with a real translated reference body inside the code marker in the right Impl file.
  3. Every external lib used by the source has an opaque (and optional axiom) in global_aux, with a @review human annotation.
  4. Spec/<Module>.lean files exist as scaffolds — import <Project>.Harness + module docstring + DO NOT MODIFY notice; they will be filled by spec_write.
  5. Test.lean has #guards for every doctest found in source (or @review human notes for the curator if absent).

What NOT to do

  • Don't leave API bodies as sorry in the curated benchmark. The body inside the code marker is the curator's translated reference implementation; pre-agent generation replaces it with sorry before the benchmark is shown to the solving agent.
  • Don't write specs in this stage. That's spec_write.
  • Don't emit Mathlib imports unless the curator's human_guidance.md explicitly authorizes it.
  • Don't introduce instance blocks for DecidableEq/BEq/Hashable on opaque types — the opaque declaration deliberately blocks decidable equality.
  • Don't translate Python print / input / file I/O. Skip those APIs and add a @review human note explaining the omission.

© sunblaze-ucb, Apache-2.0. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

Just SKILL.md in .claude/skills/vero-source-python of sunblaze-ucb/vero.

Open the folder on GitHubat commit 0a7325d

Compare with similar skills

Vero Source Python next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Vero Source Python compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Vero Source Python this skillsunblaze-ucb/vero107—~1.9kAutomated safety check: PassApache-2.0
China Travel Kittczyliu/china-travel-kit194—~1.3kAutomated safety check: PassMIT
Technology Searchfreestylefly/wesight943—~3.3kAutomated safety check: PassMIT
Translate Popython/python-docs-zh-tw284—~793Automated safety check: PassCustom licence
Obs Build LogsNuitka/Nuitka15k—~849Automated safety check: PassAGPL-3.0
Update Gui TranslationsArduPilot/MethodicConfigurator163—~1.5kAutomated safety check: PassGPL-3.0

Similar skills

  • China Travel Kit

    tczyliu/china-travel-kit

    Research and plan first-time independent trips in China with bilingual, source-aware city data and official live-check entry points.

    194 GitHub stars~1.3k tokensUpdated 1 mo ago
    Writing & ContentAuto-check passed
  • Technology Search

    freestylefly/wesight

    Search tech blogs, developer forums, and IT media (TechCrunch, Hacker News, 36氪, etc.) for software and hardware industry updates with heat ranking and EN↔CN translation.

    943 GitHub stars~3.3k tokensUpdated 6 days ago
    Writing & ContentAuto-check passed
  • Translate Po

    python/python-docs-zh-tw

    Official

    Translates PO file entries from English to Traditional Chinese (zhTW) following project conventions.

    284 GitHub stars~793 tokensUpdated 2 days ago
    Writing & ContentAuto-check passed
  • Obs Build Logs

    Nuitka/Nuitka

    Access and diagnose openSUSE Build Service (OBS) package build logs.

    15k GitHub stars~849 tokensUpdated today
    Writing & ContentAuto-check passed
  • Update Gui Translations

    ArduPilot/MethodicConfigurator

    Update existing GUI translations using AI assistance. An agent skill from ArduPilot/MethodicConfigurator.

    163 GitHub stars~1.5k tokensUpdated today
    Writing & ContentAuto-check passed
  • Check Terminology

    python/python-docs-zh-tw

    Official

    Checks terminology consistency against project glossary and identifies zhCN terms that need conversion to zhTW.

    284 GitHub stars~705 tokensUpdated 2 days ago
    Writing & ContentAuto-check passed

More from sunblaze-ucb/vero

All 16 skills in this repo
  • Vero Discover

    sunblaze-ucb/vero

    A skill your agent uses when scanning a verified source repo (Dafny, Verus, or Coq) to classify every item and produce per-file discovery markdown for human curation.

    107 GitHub stars~3.9k tokensUpdated 1 mo ago
    Auto-check: notes
  • Vero Translate

    sunblaze-ucb/vero

    A skill your agent uses when translating selected verified items from Dafny/Verus/Coq into a compilable Lean 4 benchmark.

    107 GitHub stars~4.9k tokensUpdated 1 mo ago
    Auto-check: notes
  • Vero Coq Pitfalls

    sunblaze-ucb/vero

    Load BEFORE translating any Coq item to Lean 4 to avoid known Coq→Lean pitfalls.

    107 GitHub stars~1.5k tokensUpdated 1 mo ago
    Auto-check: notes
  • Vero Dafny Pitfalls

    sunblaze-ucb/vero

    Load BEFORE translating any Dafny item to Lean 4 to avoid known Dafny→Lean pitfalls.

    107 GitHub stars~1.2k tokensUpdated 1 mo ago
    Auto-check: notes
  • Vero Lean Pitfalls

    sunblaze-ucb/vero

    Load BEFORE writing any Lean 4 translation to avoid common Lean pitfalls (universes, coercions, type-class resolution, notation).

    107 GitHub stars~1.4k tokensUpdated 1 mo ago
    Auto-check: notes
  • Vero Plan

    sunblaze-ucb/vero

    Use after vero-select to write a detailed translation plan as .vero/plan.json — the authoritative contract the TRANSLATE stage executes.

    107 GitHub stars~3.6k tokensUpdated 1 mo ago
    Auto-check: notes

Works with

Questions about Vero Source Python

What does Vero Source Python do?

Load BEFORE translating Python source to Lean 4. An agent skill from sunblaze-ucb/vero. Vero Source Python is an agent skill from sunblaze-ucb/vero. Load BEFORE translating Python source to Lean 4.

When should I use Vero Source Python?

Vero Source Python fits situations like: tasks that involve Translation.

How do I install Vero Source Python in Claude Code?

Run `npx skills add sunblaze-ucb/vero --skill vero-source-python -a claude-code`. Or copy the skill folder (.claude/skills/vero-source-python in sunblaze-ucb/vero) into .claude/skills/vero-source-python in your project. Claude Code loads it when a task matches its description.

How do I install Vero Source Python in Codex?

Run `npx skills add sunblaze-ucb/vero --skill vero-source-python -a codex`. Or copy the skill folder (.claude/skills/vero-source-python in sunblaze-ucb/vero) into .agents/skills/vero-source-python in your project. Codex loads it when a task matches its description.

Can I use Vero Source Python in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add sunblaze-ucb/vero --skill vero-source-python -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/vero-source-python, .gemini/skills/vero-source-python, .github/skills/vero-source-python and .opencode/skills/vero-source-python in your project.

What does Vero Source Python need to run?

SKILL.md names no scripts, command-line tools or credentials: Vero Source Python is instructions for the agent only. Our summary lists: Python 3.

Does Vero Source Python access the network?

SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.

Is Vero Source Python safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Vero Source Python use?

Vero Source Python is published under the Apache-2.0 licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Vero Source Python use?

About 1.9k tokens (SKILL.md is roughly 7.7k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Vero Source Python?

Skills that share tags, products or a category with Vero Source Python: China Travel Kit (tczyliu/china-travel-kit, 194 stars), Technology Search (freestylefly/wesight, 943 stars), Translate Po (python/python-docs-zh-tw, 284 stars) and Obs Build Logs (Nuitka/Nuitka, 15k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Vero Source Python?

sunblaze-ucb (a GitHub organization) maintains it in sunblaze-ucb/vero, which has 107 GitHub stars. The repository holds 16 skills in this directory. The repository was last updated on August 17, 2026.

Source: sunblaze-ucb/vero on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.