Sozio Business
README.md
# Sozio Business
Sozio Business is a standalone local MCP server for combining private company
data with 22,635 profiled Swiss open-data resources. It extends Sozio Full with
private imports, local profiling, reviewed join mappings, output controls, and
the synthetic AlpenMarkt AG demonstration.
## Boundary
The server contains no language model and makes no internal LLM calls. Claude,
Codex, or another MCP client performs research design, SQL generation, review,
method selection, interpretation, and writing. Sozio Business performs:
- local public/private catalog search;
- private CSV, JSON, Parquet, XLSX, and SQLite import;
- local Parquet normalization and profiling;
- automatic private/public join suggestions with explicit confirmation;
- reviewed private/public join mappings and a local JSONL audit trail;
- read-only DuckDB SQL and joins;
- scipy tests and statsmodels regressions;
- OpenAlex bibliographic retrieval;
- local scientific reports and reproduction bundles.
Private files, normalized data, profiles, mappings, and reports remain in the
configured local state directory. Public providers and OpenAlex receive normal
HTTP requests when their data is requested.
## Privacy modes
`SOZIO_BUSINESS_PRIVACY_MODE` accepts:
- `standard`: schema, samples, distinct values, and result rows are available;
- `protected` (default): private samples and distinct values are suppressed,
queries referencing sensitive columns are blocked, result rows are capped, and groups
below the minimum size are blocked;
- `local_only`: applies protected output controls and records that a local model
is required. The MCP server cannot technically verify the client's model.
Additional settings:
```powershell
$env:SOZIO_BUSINESS_MINIMUM_GROUP_SIZE = "5"
$env:SOZIO_BUSINESS_MAXIMUM_PRIVATE_ROWS = "100"
```
Protected mode reduces accidental disclosure but is not a complete legal or
statistical disclosure-control system. Real personal data requires a documented
governance and security review.
## Development
```powershell
uv sync --extra dev
uv run sozio-business doctor
uv run sozio-business setup-demo
uv run sozio-business mcp-server
```
## MCP Bundle
`manifest.json` uses the MCPB 0.4 UV runtime, so the host resolves the locked
Python dependencies, including compiled DuckDB/statistics packages. Build the
installable bundle with:
```powershell
npx --yes @anthropic-ai/mcpb validate
npx --yes @anthropic-ai/mcpb pack
```
The bundle includes the complete local public profile catalog. Private imports,
profiles, normalized files, reports, mappings, and `audit.jsonl` are written to
the state directory selected during installation.
`setup-demo` generates and imports five synthetic AlpenMarkt datasets:
| Resource | Format | Grain |
|---|---|---|
| stores | XLSX | one row per store |
| sales_daily | CSV | store, date, product group |
| employees_monthly | Parquet | store and month |
| campaigns | JSON | one campaign |
| energy_monthly | SQLite | store and month |
The company and all records are synthetic. `manager_email` uses the reserved
`.invalid` domain and demonstrates sensitive-column controls.
## Recommended demonstration
Ask the MCP client:
1. Set up AlpenMarkt AG and list the private profiles.
2. Find a public municipal population resource that joins through the BFS municipality number.
3. Inspect and explicitly confirm the join grain and key types.
4. Calculate store revenue per resident by municipality.
5. Estimate an OLS model for daily revenue using sales area, discount, weekend, campaign, and product group.
6. Explain assumptions and limitations, then create a scientific report and reproduction bundle.
See `examples/ALPENMARKT_ANALYSES.md` for detailed workflows.
This server cannot be deployed
Maintenance
ActivityStale
ResponsivenessNo issues