# LLM Documentation Index (Authoritative)

This directory contains the authoritative documentation used as input
context for the data-agent (LLM) when generating and validating billing SQL.

Implementation and dbt design docs live under `dbt/design/` (not in `docs/`).

LLMs MUST follow the reading order below.

----------------------------------------
1) CORE REFERENCE (Read First)
----------------------------------------

Read this first to understand all datasets, mandatory rules, and cost conventions:

- **multi-cloud-billing-core.md** (single authoritative reference)

This document defines:
- Dataset locations and partitioning
- BigQuery mandatory rules (DO NOT VIOLATE)
- Cost field conventions per cloud
- Time range guidance for all clouds
- Key schema differences (CUR 1.0 vs 2.0, nested structures)

----------------------------------------
2) CLOUD-SPECIFIC BILLING DETAILS
----------------------------------------

Read these to implement SQL correctly for each cloud:

- aws-billing-guide.md + aws-cur-field-values.md (AWS)
- gcp-billing-guide.md (GCP)
- azure-billing-guide.md (Azure)
- alibaba-billing-guide.md (Alibaba)

These documents define:
- Detailed field references
- Field value samples and distributions
- Query examples
- Tag / label extraction patterns

----------------------------------------
DEPRECATED (Archived - Do Not Reference)
----------------------------------------

The following files have been merged into `multi-cloud-billing-core.md` and moved to `_deprecated/`:
- `_deprecated/multi-cloud-billing.md`
- `_deprecated/multi-cloud-billing-base.md`
- `_deprecated/multi-cloud-billing-schema.md`

----------------------------------------
USAGE RULES FOR LLMs
----------------------------------------

- These documents are authoritative.
- Do NOT invent fields not present in these docs.
- Partition rules MUST be respected.
- If documents conflict, prefer the more specific one.
- If uncertainty exists, explicitly ask for clarification.
- Always use english for docs and code comments.
