Metadata-Version: 2.4
Name: sydes
Version: 0.1.3
Summary: System intelligence for backend systems, starting with incident analysis from logs.
Author-email: Sydes <hello@sydes.io>
License-File: LICENSE
Keywords: cli,incident-analysis,logs,observability,root-cause
Classifier: Development Status :: 3 - Alpha
Classifier: Environment :: Console
Classifier: Intended Audience :: Developers
Classifier: License :: Other/Proprietary License
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.12
Classifier: Topic :: System :: Monitoring
Classifier: Topic :: Utilities
Requires-Python: >=3.12
Requires-Dist: rich>=13.7.0
Requires-Dist: typer>=0.12.0
Description-Content-Type: text/markdown

# Sydes

System intelligence for backend systems, starting with incident analysis from logs.

Sydes helps engineers investigate suspected issues in logs using structured evidence, timelines, and AI-assisted reasoning.

## Installation

```bash
pip install sydes
```

## Before you run

Choose one model path.

`--model` is required for `sydes incident analyze`.

### OpenAI

```bash
export OPENAI_API_KEY=your_openai_api_key
```

Run with:

```bash
--model openai:gpt-4.1-mini
```

### Ollama

Make sure Ollama is running and a model is available:

```bash
ollama serve
ollama pull llama3.1
```

Run with:

```bash
--model ollama:llama3.1
```

## Quickstart

```bash
sydes incident analyze \
  --model openai:gpt-4.1-mini \
  --query "Why is checkout returning 503 errors?" \
  logs/incident.log
```

Example with a filtered incident window:

```bash
sydes incident analyze \
  validation/incident/fixtures/window_filter/*.log \
  --from "2026-03-31T10:05:00" \
  --to "2026-03-31T10:15:00" \
  --model openai:gpt-4.1-mini
```

Sample output:

```text
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
INCIDENT SUMMARY
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━

Gateway upstream timeout likely contributed to API checkout errors in the incident window

━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
INCIDENT WINDOW
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━

Mode:               filtered
Requested window:   from=2026-03-31T10:05:00+00:00 to=2026-03-31T10:15:00+00:00
Retained seeds:     7/14
Excluded untimed:   0
Start:              2026-03-31T10:05:00+00:00
End:                2026-03-31T10:14:30+00:00
Timeline events:    7

━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
TOP HYPOTHESIS
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━

Gateway upstream timeout likely contributed to API checkout errors in the incident window
The earliest high-severity signal is a gateway error indicating an upstream timeout for the /checkout endpoint at 10:10:15, followed shortly by high-severity API errors returning checkout failures.
Source:             openai:gpt-4.1-mini

━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
CONFIDENCE / STRENGTH
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━

Strength:           0.70
```

Sydes works best with focused inputs such as:

- `--query` for a suspected issue
- `--grep` for a known error pattern
- `--service` for a specific component
- `--level` for higher-signal log lines

Whole-log analysis is supported, but focused analysis is usually more reliable and actionable.

## CLI

```bash
sydes --help
sydes incident analyze --help
```
