agentleFS
williamcorrea23williamcorrea23/sap-router-skill/.agents/skills/sap-cloud-sdk-ai/SKILL.md

sap-cloud-sdk-ai

Skill1 starsChanged 4 months agoMITView on GitHub

SAP Cloud SDK for AI — generative AI hub SDK, LLM orchestration, prompt templating, model selection, orchestration service for multi-step AI workflows, document grounding, retrieval augmented generation (RAG). Use when building AI agents with SAP Cloud SDK, calling LLMs via SAP BTP GenAI Hub, or implementing RAG patterns with SAP data.

1 other project uses a version of this.

Adopted by

Most recently taken up by

The file

We split this skill into the rules it gives an agent

2 rules. About 0 are common, 2 are distinctive, and 0 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈2

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 0

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Document grounding documents must be in supported format (PDF, TXT, MD)

    line 88
  2. Distinctive:

    Always validate LLM output — hallucination risk with SAP technical content

    line 89

≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

SAP Cloud SDK for AI

Generative AI development on SAP BTP — LLM orchestration, prompt management, RAG.

Python SDK

from gen_ai_hub.orchestration import OrchestrationService

# Orchestration with templating and grounding
service = OrchestrationService(
    api_url="https://api.ai.core.prod.<region>.aws.cloud.sap/v2",
    client_id="...", client_secret="..."
)

# Define a prompt template
template = '''
System: You are an SAP procurement expert. Answer using only provided context.

Context: {{?grounding_context}}

User: {{?user_input}}
'''

result = service.invoke(
    template=template,
    grounding={"type": "document", "source": "sap-procurement-docs"},
    model={"name": "gpt-4"},
    input={"user_input": "How do I create a purchase order?"}
)
print(result.content)

Document Grounding

# Upload SAP documents for RAG
service.upload_document(
    name="sap-procurement-docs",
    content=open("procurement_guide.pdf", "rb"),
    metadata={"category": "SAP_MM", "language": "EN"}
)

# Query with grounding
response = service.query_with_grounding(
    question="What BAPI creates a purchase order?",
    document_names=["sap-procurement-docs"],
    top_k=3
)

Model Selection

ModelProviderBest For
GPT-4 / GPT-4oOpenAIComplex reasoning, code generation
Codex Opus / SonnetAnthropicAnalysis, structured output
Llama 3Meta (self-hosted)Cost-sensitive, offline scenarios
Gemini ProGoogleMultimodal, long context

Multi-Step Orchestration

# Chain: classify → route → generate → validate
orchestrator = OrchestrationService()

steps = [
    {"name": "classify", "template": classify_template, "model": "gpt-4o-mini"},
    {"name": "generate", "template": generate_template, "model": "gpt-4"},
    {"name": "validate", "template": validate_template, "model": "gpt-4o-mini"}
]

result = orchestrator.run_pipeline(steps=steps, input={"question": user_input})

Gotchas

  • GenAI Hub requires AI Core entitlement on BTP subaccount
  • Rate limits vary by model provider (OpenAI vs Anthropic vs Meta)
  • Document grounding documents must be in supported format (PDF, TXT, MD)
  • Always validate LLM output — hallucination risk with SAP technical content

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.