# Build Schema Prompts

Diseño original para fuzzygraph.

## Funciones a implementar

### 1. build_entity_schema_prompt

- **Dominio:** datascience
- **Lang:** Python
- **Purity:** pure
- **Signature:** `build_entity_schema_prompt(entity_presets: list[dict]) -> str`
- **Descripcion:** Genera la seccion del system prompt que describe los entity types disponibles para extraccion. Formatea los presets del registry en texto legible para el LLM.
- **Input:** Lista de presets tal como estan en fuzzygraph:
  ```python
  [
    {"type_ref": "osint_person_go_cybersecurity", "label": "Person",
     "metadata_fields": ["full_name", "alias", "nationality", "dob", "risk_score"]},
    ...
  ]
  ```
- **Output:** String formateado:
  ```
  Entity types available for extraction:

  1. Person (type_ref: osint_person_go_cybersecurity)
     Attributes: full_name, alias, nationality, dob, risk_score

  2. Organization (type_ref: osint_organization_go_cybersecurity)
     Attributes: legal_name, country, sector, founded, risk_score

  ...
  ```
- **Tests:** lista con varios presets, lista vacia, preset sin metadata_fields

### 2. build_relation_schema_prompt

- **Dominio:** datascience
- **Lang:** Python
- **Purity:** pure
- **Signature:** `build_relation_schema_prompt(relation_types: list[str]) -> str`
- **Descripcion:** Genera la seccion del system prompt con los tipos de relacion permitidos.
- **Input:** `["funds", "employs", "communicates_with", ...]`
- **Output:**
  ```
  Allowed relation types:
  funds, employs, communicates_with, owns, operates, controls,
  affiliated_with, located_at, resolves_to, registered_by, hosts,
  exploits, attributed_to, related_to
  ```
- **Tests:** lista normal, lista vacia
