Agent skill

SenseNova Environment Doctor

by OpenSenseNova in OpenSenseNova/SenseNova-Skills

Checks that the SenseNova-Skills environment is ready by validating the sn-image-base install, Python dependencies and API variables, saving missing settings to .env.

MITAuto-check: notesDevelopment

Install SenseNova Environment Doctor

skills CLI
$ npx skills add OpenSenseNova/SenseNova-Skills --skill sn-image-doctor -a claude-code

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

GitHub CLI
$ gh skill install OpenSenseNova/SenseNova-Skills sn-image-doctor --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/OpenSenseNova/SenseNova-Skills.git skills-src && mkdir -p .claude/skills && cp -r skills-src/skills/sn-image-doctor .claude/skills/sn-image-doctor && 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
sn-image-doctor
GitHub stars
5.7k
Token cost
~1.4k tokens
SKILL.md length
249 words
Files
2 (incl. scripts)
Skills in repo
36
Repo updated
First seen
Licence
MIT

At a glance

Checks that the SenseNova-Skills environment is ready by validating the sn-image-base install, Python dependencies and API variables, saving missing settings to .env.

  • Works in 4 steps: Verify network connectivity → Check firewall settings → Verify API endpoint URLs are correct → …
  • Setting up SenseNova-Skills for the first time
  • SKILL.md covers Overview, Usage, Output Format and Troubleshooting, plus 4 more sections
  • Runs Python scripts from its folder; calls python, pip and curl; reaches token.sensenova.cn; needs SN_API_KEY and SN_CHAT_API_KEY

What it does

This is an infrastructure skill, labeled tier 0, meant to run before the other SenseNova skills. `scripts/check_environment.py` verifies that `sn-image-base` is present, that its Python dependencies are installed and that the required environment variables are set, printing the result of each numbered step and a separate error report when a check fails.

When a required variable is missing, the script prompts you for it, saves it to `.env`, reloads the environment and suggests restarting the agent if the reload fails. Variables fall back from capability-specific to shared to global, so text calls try `SN_TEXT_API_KEY`, then `SN_CHAT_API_KEY`, then `SN_API_KEY`. Troubleshooting notes cover a missing `sn-image-base` folder, installing its `requirements.txt` and API connectivity.

When your agent uses it

  • Setting up SenseNova-Skills for the first time
  • A SenseNova skill fails because of a missing dependency or API key
  • Verifying the environment after changing the gateway URL or keys

Example prompts

  • “Run the SenseNova environment check and tell me what is missing.”
  • “My SenseNova image skill says the API key is not set. Diagnose the setup.”
  • “Configure the SenseNova API variables in .env and reload the environment.”

Requirements

  • Python
  • The SenseNova-Skills project with `sn-image-base`
  • A SenseNova API key and base URL

Workflow steps

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

  1. Verify network connectivity
  2. Check firewall settings
  3. Verify API endpoint URLs are correct
  4. Test with curl

What it can do on your machine

Read from SKILL.md and the folder at commit 7838651. 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

    Ships 1 file in scripts/ (Python), which the agent can run.

    Shell commands in SKILL.md call:

    • python
    • pip
    • curl

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

  • Network

    Hosts in commands or code, which the agent is likely to contact:

    • token.sensenova.cn

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

  • Credentials

    Names these keys or tokens, usually read from environment variables:

    • SN_API_KEY
    • SN_CHAT_API_KEY
    • SN_IMAGE_GEN_API_KEY
    • SN_TEXT_API_KEY
    • SN_VISION_API_KEY

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

Context cost

SenseNova Environment Doctor loads about 1.4k tokens when it runs. Until then it costs about 87 tokens; SKILL.md has 249 words of instructions outside code blocks.

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

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: notes

The automated check noted patterns worth knowing about, such as sudo or a known installer.

  • NoteMentions a .env fileSKILL.md:7
    them to .env file. After configuration, reloads environment and suggests agent restart if needed.
  • NoteMentions a .env fileSKILL.md:33
    ing required variables and save them to `.env`
  • NoteMentions a .env fileSKILL.md:66
    er values below to save them to /path/to/.env.
  • NoteMentions a .env fileSKILL.md:71
    ✅ Saved to /path/to/.env: SN_API_KEY
  • NoteMentions a .env fileSKILL.md:82
    ✅ Saved to /path/to/.env: SN_API_KEY
  • NoteMentions a .env fileSKILL.md:151
    # Or create a .env file
  • NoteMentions a .env fileSKILL.md:152
    cat > .env << EOF
  • NoteMentions a .env fileSKILL.md:159
    # Load .env file
  • NoteMentions a .env fileSKILL.md:160
    source .env  # Or use a tool like python-dotenv

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); the scripts in this folder are not scanned.

SKILL.md

The full file from OpenSenseNova/SenseNova-Skills at commit 7838651, republished under its MIT licence (© OpenSenseNova). 249 words, ~1,389 tokens.

Download SKILL.mdSave it as .claude/skills/sn-image-doctor/SKILL.md (or your agent's skills folder). This skill also uses 1 other file; get the full folder from GitHub.
name
sn-image-doctor
description
Environment diagnostic skill for SenseNova-Skills project. Checks that sn-image-base is properly installed and configured, validates dependencies and environment variables. Prompts user to configure missing required variables and saves them to .env file. After configuration, reloads environment and suggests agent restart if needed.
triggers
SenseNova-Skills环境检查, SenseNova-Skills doctor, sn环境检查, sn-image-doctor, environment check, health check, 诊断环境
metadata.project
SenseNova-Skills
metadata.tier
0
metadata.category
infrastructure
metadata.user_visible
true

sn-image-doctor

Overview

sn-image-doctor is an infrastructure skill (tier 0) that validates the SenseNova-Skills environment before running other skills. It ensures SenseNova-Skills project is properly installed and configured.

This skill performs comprehensive checks including:

  • Installation verification of SenseNova-Skills project
  • Python dependency validation
  • Environment variable configuration checks, with interactive prompts to configure missing required variables and save them to .env
  • Automatic environment reload after configuration changes, with agent restart suggestion if reload fails

Usage

Run the doctor check to validate your environment:

bash
# Basic check
python scripts/check_environment.py

# Verbose output with detailed diagnostics
python scripts/check_environment.py --verbose

Output Format

Text Output
=== SenseNova-Skills Environment Check ===

[1/3] Checking sn-image-base installation...
  ✅ Installation looks good

[2/3] Checking Python dependencies...
  ✅ Python 3.11.0
  ✅ All required packages installed

[3/3] Checking environment variables...
  ❌ SN_IMAGE_GEN_API_KEY: Image generation API key is not set; configure SN_API_KEY, or configure SN_IMAGE_GEN_API_KEY only for an image-generation-specific override

  Some required environment variables are missing.
  Enter values below to save them to /path/to/.env.
  Press Enter to skip a variable.

  SN_API_KEY: <user input>

  ✅ Saved to /path/to/.env: SN_API_KEY
  🔄 Reloading environment...
  ✅ Environment reloaded successfully

=== Summary ===
✅ Environment is properly configured

If reload fails, the output will suggest restarting the agent:

  ✅ Saved to /path/to/.env: SN_API_KEY
  🔄 Reloading environment...
  ⚠️  Failed to reload environment: <error message>
  💡 Suggestion: Restart the agent to apply new configuration
Error Output

When checks fail:

=== SenseNova-Skills Environment Check ===

[1/3] Checking sn-image-base installation...
  ❌ sn-image-base directory not found
  Expected location: /path/to/skills/sn-image-base

[2/3] Checking Python dependencies...
  ❌ Missing packages: httpx, pillow
  Run: pip install -r skills/sn-image-base/requirements.txt

=== Summary ===
❌ Environment check failed
Please fix the errors above before using SenseNova-Skills.

Troubleshooting

sn-image-base Not Found

Problem: sn-image-base directory not found

Solution:

bash
# Ensure you're in the project root
cd /path/to/SenseNova-Skills

# Verify the directory exists
ls -la skills/sn-image-base
Missing Dependencies

Problem: Required Python packages not installed

Solution:

bash
# Install dependencies
pip install -r skills/sn-image-base/requirements.txt

# Or use a virtual environment
python -m venv .venv
source .venv/bin/activate  # On Windows: .venv\Scripts\activate
pip install -r skills/sn-image-base/requirements.txt
Missing Environment Variables

Problem: Required environment variables not set

Solution:

bash
# If all capabilities use the same gateway, set only the global values.
export SN_API_KEY="your-api-key"
export SN_BASE_URL="https://your-api-endpoint.com"

# Or create a .env file
cat > .env << EOF
SN_API_KEY=your-api-key
SN_BASE_URL=https://token.sensenova.cn/v1
SN_CHAT_TYPE=openai-completions
SN_CHAT_MODEL=sensenova-6.8-flash-lite
EOF

# Load .env file
source .env  # Or use a tool like python-dotenv

Fallback priority is capability-specific variable > domain shared variable > global variable. For example, text calls use SN_TEXT_API_KEY -> SN_CHAT_API_KEY -> SN_API_KEY; vision calls use SN_VISION_API_KEY -> SN_CHAT_API_KEY -> SN_API_KEY; image generation uses SN_IMAGE_GEN_API_KEY -> SN_API_KEY.

API Connectivity Issues

Problem: Cannot reach API endpoints

Solution:

  1. Verify network connectivity

  2. Check firewall settings

  3. Verify API endpoint URLs are correct

  4. Test with curl:

    bash
    curl -I https://your-api-endpoint.com

Integration with Other Skills

This skill is designed to be run before using other skills in the SenseNova-Skills project:

bash
# 1. Run doctor check
python skills/sn-image-doctor/scripts/check_environment.py

# 2. If checks pass, use other skills
python skills/sn-image-base/scripts/sn_agent_runner.py sn-image-generate \
    --prompt "A beautiful landscape"

Command-Line Options

OptionDescription
--verboseShow detailed diagnostic information
--helpShow help message

Exit Codes

CodeMeaning
0All checks passed
1One or more checks failed

See Also

  • sn-image-base/SKILL.md - Base-layer skill documentation
  • sn-image-base/references/api_spec.md - API specification
  • sn-infographic/SKILL.md - Example of a skill that depends on sn-image-base

© OpenSenseNova, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

SKILL.md and 1 other file (scripts) in skills/sn-image-doctor of OpenSenseNova/SenseNova-Skills.

  • SKILL.md
  • scripts/check_environment.py

Open the folder on GitHubat commit 7838651

Compare with similar skills

SenseNova Environment Doctor 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.

SenseNova Environment Doctor compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
SenseNova Environment Doctor this skillOpenSenseNova/SenseNova-Skills5.7k—~1.4kAutomated safety check: NotesMIT
Trellis Session Insightmindfold-ai/Trellis15k4 repos~1.7kAutomated safety check: PassAGPL-3.0
Native Data FetchingCherryHQ/cherry-studio-app4k6 repos~2.9kAutomated safety check: NotesMIT
Debugging Executionsn8n-io/n8n207k—~2.6kAutomated safety check: PassCustom licence
Aoti Debugpytorch/pytorch104k1 repos~1.7kAutomated safety check: PassCustom licence
Herdr Throwaway Reproductionherdrdev/herdr43k—~2.4kAutomated safety check: PassApache-2.0

Similar skills

  • Trellis Session Insight

    mindfold-ai/Trellis

    Reach into past AI conversation history through the trellis mem CLI.

    15k GitHub starsUsed in 4 repos~1.7k tokens
    DevelopmentAuto-check passed
  • Native Data Fetching

    CherryHQ/cherry-studio-app

    A skill your agent uses when implementing or debugging ANY network request, API call, or data fetching.

    4k GitHub starsUsed in 6 repos~2.9k tokens
    DevelopmentAuto-check: notes
  • Official

    Debug failed or wrong-output workflow executions using executions tools.

    207k GitHub stars~2.6k tokensUpdated today
    DevelopmentAuto-check passed
  • Aoti Debug

    pytorch/pytorch

    Debug AOTInductor (AOTI) errors and crashes. An agent skill from pytorch/pytorch.

    104k GitHub starsUsed in 1 repo~1.7k tokens
    DevelopmentAuto-check passed
  • Runs a disposable, uniquely named Herdr session inside an existing one so runtime, pane, terminal or API bugs can be reproduced without touching the main session.

    43k GitHub stars~2.4k tokensUpdated 2 days ago
    DevelopmentAuto-check passed
  • Systematic Debugging

    ultralisp/ultralisp

    A skill your agent uses when encountering any bug, test failure, or unexpected behavior, before proposing fixes

    258 GitHub starsUsed in 52 repos~2.4k tokens
    DevelopmentAuto-check passed

More from OpenSenseNova/SenseNova-Skills

All 36 skills in this repo
  • SN Motion HTML

    OpenSenseNova/SenseNova-Skills

    Builds HTML stories where one continuous camera journey advances with page progress, using researched structure, AI stills, Seedance video clips and browser QA.

    5.7k GitHub stars~2.2k tokensUpdated 2 days ago
    Auto-check: notes
  • SenseNova PPT Fallback Tools

    OpenSenseNova/SenseNova-Skills

    Fallback scripts for web search, image search and download, and image generation that PPT skills use only when the host agent lacks or fails its own tools.

    5.7k GitHub stars~575 tokensUpdated 2 days ago
    Auto-check: notes
  • SenseNova PPT Workbench

    OpenSenseNova/SenseNova-Skills

    Opens the PPT Workbench web editor for an existing SenseNova HTML slide deck so you can preview, inspect and visually edit it without regenerating.

    5.7k GitHub stars~2.5k tokensUpdated 2 days ago
    Auto-check: notes
  • SenseNova PPT Creative Renderer

    OpenSenseNova/SenseNova-Skills

    Turns an approved slide outline into a full-page image for every slide, one 16:9 PNG per page, and optionally packages the set into a PPTX.

    5.7k GitHub stars~1.2k tokensUpdated 2 days ago
    Auto-check passed
  • SenseNova PPT Entry

    OpenSenseNova/SenseNova-Skills

    Entry point for SenseNova presentation generation: creates a task folder, picks depth, output format and design richness, and routes to the right PPT skill.

    5.7k GitHub stars~2.7k tokensUpdated 2 days ago
    Auto-check: notes
  • China Market Open Data Search

    OpenSenseNova/SenseNova-Skills

    Researches Chinese market, macro, trade, procurement, listed-company and regulatory information from free official sources that need no sign-up or API key.

    5.7k GitHub stars~954 tokensUpdated 2 days ago
    Auto-check: notes

Questions about SenseNova Environment Doctor

What does SenseNova Environment Doctor do?

Checks that the SenseNova-Skills environment is ready by validating the sn-image-base install, Python dependencies and API variables, saving missing settings to .env. This is an infrastructure skill, labeled tier 0, meant to run before the other SenseNova skills.py` verifies that `sn-image-base` is present, that its Python dependencies are installed and that the required environment variables are set, printing the result of each numbered step and a separate error report when a check fails.

When should I use SenseNova Environment Doctor?

SenseNova Environment Doctor fits situations like: setting up SenseNova-Skills for the first time; A SenseNova skill fails because of a missing dependency or API key; verifying the environment after changing the gateway URL or keys.

How do I install SenseNova Environment Doctor in Claude Code?

Run `npx skills add OpenSenseNova/SenseNova-Skills --skill sn-image-doctor -a claude-code`. Or copy the skill folder (skills/sn-image-doctor in OpenSenseNova/SenseNova-Skills) into .claude/skills/sn-image-doctor in your project. Claude Code loads it when a task matches its description.

How do I install SenseNova Environment Doctor in Codex?

Run `npx skills add OpenSenseNova/SenseNova-Skills --skill sn-image-doctor -a codex`. Or copy the skill folder (skills/sn-image-doctor in OpenSenseNova/SenseNova-Skills) into .agents/skills/sn-image-doctor in your project. Codex loads it when a task matches its description.

Can I use SenseNova Environment Doctor 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 OpenSenseNova/SenseNova-Skills --skill sn-image-doctor -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/sn-image-doctor, .gemini/skills/sn-image-doctor, .github/skills/sn-image-doctor and .opencode/skills/sn-image-doctor in your project.

What does SenseNova Environment Doctor need to run?

Going by SKILL.md and its folder, SenseNova Environment Doctor needs Python for the scripts in its folder, the command-line tools its instructions call (python, pip and curl) and credentials named SN_API_KEY, SN_CHAT_API_KEY, SN_IMAGE_GEN_API_KEY and SN_TEXT_API_KEY. Our summary lists: Python; The SenseNova-Skills project with `sn-image-base`; A SenseNova API key and base URL.

Does SenseNova Environment Doctor access the network?

SKILL.md names 1 domain. In commands or code: token.sensenova.cn; the agent is likely to contact it when it follows the instructions. This is read from the text; nothing was executed.

Is SenseNova Environment Doctor safe to install?

Our automated static check of SKILL.md found notes only (mentions a .env file), nothing it rates as a warning. It is not a guarantee. The check reads SKILL.md only: the scripts in the folder are not scanned, so read them before running anything.

What licence does SenseNova Environment Doctor use?

SenseNova Environment Doctor is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does SenseNova Environment Doctor use?

About 1.4k tokens (SKILL.md is roughly 5.6k 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 SenseNova Environment Doctor?

Skills that share tags, products or a category with SenseNova Environment Doctor: Trellis Session Insight (mindfold-ai/Trellis, 15k stars), Native Data Fetching (CherryHQ/cherry-studio-app, 4k stars), Debugging Executions (n8n-io/n8n, 207k stars) and Aoti Debug (pytorch/pytorch, 104k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains SenseNova Environment Doctor?

OpenSenseNova (a GitHub organization) maintains it in OpenSenseNova/SenseNova-Skills, which has 5,749 GitHub stars. The repository holds 36 skills in this directory. The repository was last updated on October 9, 2026.

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