技能创建器
skill-creator
创建、改进和评估自定义技能,把专业流程转化为可重复使用的 AI 能力。
pandasai【数据与研究】Routes PandasAI tasks for conversational dataframe analysis, semantic data layers, custom skills, sandboxed execution, CLI usage, and repo maintenance guidance.
独立 GitHub 快照 · 自动分类 · 以原作者文档为准
Use this skill when a task involves the PandasAI Python package (pandasai),
especially natural-language analysis over pandas dataframes, semantic dataset
schemas, PandasAI custom skills, sandboxed code execution, or the pai CLI.
PandasAI 3.x turns dataframes and semantic datasets into conversational analysis surfaces. It uses an LLM to generate Python/SQL code, executes that code locally or through an optional sandbox, and returns typed response objects.
For a fresh environment, install the core package and the LLM/provider extension that matches the user's provider:
pip install pandasai
pip install pandasai-litellm # common provider bridge
# or: pip install pandasai-openai # OpenAI/Azure extension
Minimum import check:
python - <<'PY'
import pandasai as pai
from pandasai import Agent, DataFrame
print("pandasai import ok", pai)
print("DataFrame", DataFrame)
print("Agent", Agent)
PY
For local deterministic smoke checks without real LLM credentials, run the bundled diagnostic:
python scripts/check_pandasai_environment.py --chat-smoke
Read references/repo-provenance.md before
refreshing this skill or comparing it against a checkout. Read
references/package-overview.md for the
shared public API map and references/troubleshooting.md
for cross-cutting install/import/optional-dependency issues.
| User task | Read next |
|---|---|
Configure an LLM, ask questions against a DataFrame, inspect response objects, use Agent, debug generated code, or migrate from SmartDataframe/SmartDatalake | sub-skills/conversational-analysis/SKILL.md |
Create/load semantic datasets, validate schema.yaml, define CSV/parquet/SQL/view sources, transformations, group_by, or relation rules | sub-skills/semantic-layer/SKILL.md |
Add custom callable functions to PandasAI with @pai.skill, inspect SkillType, or manage the global skills registry | sub-skills/custom-skills/SKILL.md |
Decide whether to sandbox generated code, use the optional Docker sandbox, or implement/check a custom Sandbox subclass | sub-skills/sandbox-and-security/SKILL.md |
Use the pai CLI, validate/login with a PandaBI API key, run guided dataset creation, or follow repo maintainer commands | sub-skills/cli-and-project-ops/SKILL.md |
DataFrame, or
a semantic dataset path..chat() or pai.chat(), make sure an LLM is configured
with pai.config.set({"llm": llm}) unless the user is deliberately running a
FakeLLM smoke test.organization/dataset
with lowercase hyphenated segments and that generated files belong under a
project datasets/ directory.pandasai-litellm, pandasai-openai, pandasai-sql[...], or
pandasai-docker.execute_sql_query(...) function
and a result = {"type": ..., "value": ...} dictionary.plot result type internally and return a chart
response object; save or show charts through response methods.SmartDataframe and SmartDatalake are compatibility wrappers that emit
deprecation warnings; prefer pai.DataFrame, pai.chat, and Agent for new
code.references/package-overview.md summarizes
the package surface, optional extensions, and route ownership.references/troubleshooting.md lists
cross-cutting install, import, LLM, SQL, sandbox, and project-root issues.references/maintainer-notes.md captures
contributor-oriented test/lint/package guidance without requiring full extras
for ordinary package use.scripts/check_pandasai_environment.py
checks imports, version metadata, CLI availability, optional extensions, and a
deterministic offline chat smoke.Use a generic pandas/data-science skill instead if the user only needs standard pandas operations without PandasAI APIs. Use an LLM provider-specific or gateway skill when the problem is provider routing, billing, or model hosting outside PandasAI's configuration surface. Use a Docker or security-hardening skill when the task is container infrastructure rather than PandasAI sandbox integration.