# yasirfarooq76/shakeela-begum-protocol-sbp- architecture

> Architecture diagram of the GitHub repository yasirfarooq76/shakeela-begum-protocol-sbp-, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-09-26). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/yasirfarooq76/shakeela-begum-protocol-sbp-
- Repository: https://github.com/yasirfarooq76/shakeela-begum-protocol-sbp-

## Overview

SBP is a lightweight Python prompting tool: a prompt is transformed through Negation, Interrogation, and Affirmation, and can also be run through model-backed workflows or benchmarked. The README documents the stages and benchmark modes; sampled source confirms a CLI, plug-in registry, provider implementations, and scoring/reporting helpers. Since excerpts omit much of the orchestration and transformation code, uncertain internal calls are not shown.

Main entry points: [`sbp.py`](https://github.com/yasirfarooq76/shakeela-begum-protocol-sbp-/blob/main/sbp.py) (Provider Base)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_protocol["Protocol"]
  node_cli["CLI<br/>[sbp.py]"]
  node_transform["Prompt Transform<br/>[sbp.py]"]
  node_negation["Negation<br/>[sbp.py]"]
  node_interrogation["Interrogation<br/>[sbp.py]"]
  node_affirmation["Affirmation<br/>[sbp.py]"]
  node_run["Model Run<br/>[sbp.py]"]
  node_plugins["Plug-in Registry<br/>[sbp.py]"]
end

subgraph group_providers["Model Providers"]
  node_provider["Provider Base<br/>[sbp.py]"]
  node_mock["Mock Provider<br/>[sbp.py]"]
  node_anthropic["Anthropic Provider<br/>[sbp.py]"]
  node_openai["OpenAI-compatible Provider<br/>[sbp.py]"]
end

subgraph group_evaluation["Evaluation"]
  node_benchmark["Benchmark<br/>[sbp.py]"]
  node_judge["Condition Judge<br/>[sbp.py]"]
  node_scores["Score Aggregation<br/>[sbp.py]"]
  node_report["Report Output<br/>[sbp.py]"]
end

node_user(("User"))
node_model_service(("Model Service"))

node_user -->|"submits prompt"| node_cli
node_cli -->|"dispatches transform"| node_transform
node_transform -->|"rewrites prompt"| node_negation
node_transform -->|"rewrites prompt"| node_interrogation
node_transform -->|"forms response"| node_affirmation
node_cli -->|"dispatches run"| node_run
node_run -->|"requests completion"| node_provider
node_anthropic -.->|"sends request"| node_model_service
node_openai -.->|"sends request"| node_model_service
node_mock -->|"implements"| node_provider
node_anthropic -->|"implements"| node_provider
node_openai -->|"implements"| node_provider
node_cli -->|"dispatches bench"| node_benchmark
node_benchmark -->|"evaluates conditions"| node_judge
node_judge -->|"requests completion"| node_provider
node_judge -->|"returns scores"| node_scores
node_scores -->|"formats results"| node_report

click node_cli "https://github.com/yasirfarooq76/shakeela-begum-protocol-sbp-/blob/main/sbp.py"
click node_transform "https://github.com/yasirfarooq76/shakeela-begum-protocol-sbp-/blob/main/sbp.py"
click node_negation "https://github.com/yasirfarooq76/shakeela-begum-protocol-sbp-/blob/main/sbp.py"
click node_interrogation "https://github.com/yasirfarooq76/shakeela-begum-protocol-sbp-/blob/main/sbp.py"
click node_affirmation "https://github.com/yasirfarooq76/shakeela-begum-protocol-sbp-/blob/main/sbp.py"
click node_run "https://github.com/yasirfarooq76/shakeela-begum-protocol-sbp-/blob/main/sbp.py"
click node_plugins "https://github.com/yasirfarooq76/shakeela-begum-protocol-sbp-/blob/main/sbp.py"
click node_provider "https://github.com/yasirfarooq76/shakeela-begum-protocol-sbp-/blob/main/sbp.py"
click node_mock "https://github.com/yasirfarooq76/shakeela-begum-protocol-sbp-/blob/main/sbp.py"
click node_anthropic "https://github.com/yasirfarooq76/shakeela-begum-protocol-sbp-/blob/main/sbp.py"
click node_openai "https://github.com/yasirfarooq76/shakeela-begum-protocol-sbp-/blob/main/sbp.py"
click node_benchmark "https://github.com/yasirfarooq76/shakeela-begum-protocol-sbp-/blob/main/sbp.py"
click node_judge "https://github.com/yasirfarooq76/shakeela-begum-protocol-sbp-/blob/main/sbp.py"
click node_scores "https://github.com/yasirfarooq76/shakeela-begum-protocol-sbp-/blob/main/sbp.py"
click node_report "https://github.com/yasirfarooq76/shakeela-begum-protocol-sbp-/blob/main/sbp.py"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_cli,node_transform,node_negation,node_interrogation,node_affirmation,node_run,node_plugins,node_user toneBlue
class node_provider,node_mock,node_anthropic,node_openai toneAmber
class node_benchmark,node_judge,node_scores,node_report toneMint
class node_model_service toneIndigo
```

## Components

### Protocol

- [CLI](https://github.com/yasirfarooq76/shakeela-begum-protocol-sbp-/blob/main/sbp.py): `sbp.py`
- [Prompt Transform](https://github.com/yasirfarooq76/shakeela-begum-protocol-sbp-/blob/main/sbp.py): `sbp.py`
- [Negation](https://github.com/yasirfarooq76/shakeela-begum-protocol-sbp-/blob/main/sbp.py): `sbp.py`
- [Interrogation](https://github.com/yasirfarooq76/shakeela-begum-protocol-sbp-/blob/main/sbp.py): `sbp.py`
- [Affirmation](https://github.com/yasirfarooq76/shakeela-begum-protocol-sbp-/blob/main/sbp.py): `sbp.py`
- [Model Run](https://github.com/yasirfarooq76/shakeela-begum-protocol-sbp-/blob/main/sbp.py): `sbp.py`
- [Plug-in Registry](https://github.com/yasirfarooq76/shakeela-begum-protocol-sbp-/blob/main/sbp.py): `sbp.py`

### Model Providers

- [Provider Base](https://github.com/yasirfarooq76/shakeela-begum-protocol-sbp-/blob/main/sbp.py): `sbp.py`
- [Mock Provider](https://github.com/yasirfarooq76/shakeela-begum-protocol-sbp-/blob/main/sbp.py): `sbp.py`
- [Anthropic Provider](https://github.com/yasirfarooq76/shakeela-begum-protocol-sbp-/blob/main/sbp.py): `sbp.py`
- [OpenAI-compatible Provider](https://github.com/yasirfarooq76/shakeela-begum-protocol-sbp-/blob/main/sbp.py): `sbp.py`

### Evaluation

- [Benchmark](https://github.com/yasirfarooq76/shakeela-begum-protocol-sbp-/blob/main/sbp.py): `sbp.py`
- [Condition Judge](https://github.com/yasirfarooq76/shakeela-begum-protocol-sbp-/blob/main/sbp.py): `sbp.py`
- [Score Aggregation](https://github.com/yasirfarooq76/shakeela-begum-protocol-sbp-/blob/main/sbp.py): `sbp.py`
- [Report Output](https://github.com/yasirfarooq76/shakeela-begum-protocol-sbp-/blob/main/sbp.py): `sbp.py`

### Other components

- **User**
- **Model Service**

## Connections

- User → CLI: submits prompt
- CLI → Prompt Transform: dispatches transform
- Prompt Transform → Negation: rewrites prompt
- Prompt Transform → Interrogation: rewrites prompt
- Prompt Transform → Affirmation: forms response
- CLI → Model Run: dispatches run
- Model Run → Provider Base: requests completion
- Anthropic Provider → Model Service: sends request
- OpenAI-compatible Provider → Model Service: sends request
- Mock Provider → Provider Base: implements
- Anthropic Provider → Provider Base: implements
- OpenAI-compatible Provider → Provider Base: implements
- CLI → Benchmark: dispatches bench
- Benchmark → Condition Judge: evaluates conditions
- Condition Judge → Provider Base: requests completion
- Condition Judge → Score Aggregation: returns scores
- Score Aggregation → Report Output: formats results
