Metadata-Version: 2.4
Name: story-lifecycle
Version: 0.2.0
Summary: AI-powered development workflow orchestrator — from TAPD/Jira story to production
Author: zhaozihao
License: MIT
License-File: LICENSE
Keywords: ai,claude-code,devtools,orchestrator,workflow
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.12
Requires-Python: >=3.10
Requires-Dist: click>=8.1.0
Requires-Dist: fastapi>=0.115.0
Requires-Dist: httpx>=0.27.0
Requires-Dist: langgraph-checkpoint-sqlite>=3.0
Requires-Dist: langgraph>=0.2.0
Requires-Dist: pyyaml>=6.0
Requires-Dist: rich>=13.0.0
Requires-Dist: uvicorn[standard]>=0.30.0
Provides-Extra: dev
Requires-Dist: build>=1.0; extra == 'dev'
Requires-Dist: pytest-asyncio>=0.24.0; extra == 'dev'
Requires-Dist: pytest>=8.0; extra == 'dev'
Requires-Dist: ruff>=0.11.0; extra == 'dev'
Requires-Dist: textual>=3.0; extra == 'dev'
Requires-Dist: twine>=6.0; extra == 'dev'
Provides-Extra: tui
Requires-Dist: textual>=3.0; extra == 'tui'
Description-Content-Type: text/markdown

# Story Lifecycle Manager

AI-powered development workflow orchestrator — from TAPD/Jira story to production.

## Platform Support

| Platform | CLI + DB | AI Execution (tmux/ttyd) |
|----------|----------|--------------------------|
| **Linux** | Full | Full |
| **macOS** | Full | Full (install tmux: `brew install tmux ttyd`) |
| **Windows (native)** | Full | Not supported — use WSL2 |
| **Windows (WSL2)** | Full | Full |

### Why Windows native doesn't support AI execution

tmux and ttyd depend on Unix pseudo-terminals (PTY), `fork()`, and POSIX signals — APIs not available on native Windows. All major AI coding CLI tools (Claude Code, Aider) have the same limitation.

**Recommended setup on Windows:**

```powershell
# In WSL2 Ubuntu
sudo apt install tmux ttyd
pip install story-lifecycle
story serve
```

## Quick Start

```bash
# Install
pip install story-lifecycle       # not yet on PyPI — use `pip install -e .`

# First-run setup: configure LLM provider & API key
story setup

# Check system environment
story doctor

# Start orchestrator in one terminal
story serve

# Create a story in another terminal
story new STORY-123 --title "Add login feature"

# Watch progress
story board

# Interact with the AI (Linux/macOS/WSL only)
story enter STORY-123
```

## Profiles

- `minimal` (default): design → implement → test (3 stages)
- `standard`: full 14-stage flow (coming in Phase 2)
- Custom: drop a YAML in `~/.story-lifecycle/profiles/`

## LLM Router

The orchestrator uses an LLM API for routing decisions (provider selection, prompt generation). If no API key is configured, it falls back to rule-based routing automatically.

- **With API key**: LLM-driven routing with intelligent provider/model selection
- **Without API key**: Rule-based fallback — works out of the box for basic flows

Configure via `story setup` or edit `~/.story-lifecycle/config.yaml` directly.

## CLI Commands

```
story setup                        Configure LLM provider & API key
story doctor                       Check system environment
story new <KEY> --title "..."      Create a new story
story board                        Show all active stories
story enter <KEY>                  Open terminal to interact with AI
story status <KEY>                 Show story details
story skip <KEY> --stage <NAME>   Skip a stage
story fail <KEY>                   Mark as blocked
story resume <KEY>                 Resume a blocked story
story serve                        Start the orchestrator server
```

## License

MIT
