feat: expose logical conversation rounds over flat turn history
Los mantenedores suelen responder en 1 día
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 5/5
- Tiempo estimado
- Más de una semana
- Aptitud para principiantes
- 45/100
- Tipo de issue
- Nueva funcionalidad
- Claridad
- Bastante claro
- Estado de actividad
- Tranquilo
- Stack tecnológico
- python
- Área
- backend-api-design
Línea de trabajo
Empieza en chatlas/_chat.py con get_turns(), get_last_turn() y los helpers de partial-turn, y después inspecciona los tipos de turn y partial_reason en chatlas/_turn.py. Revisa el commit 59bbe9d4 de Ellmer como comparación, establece los nombres públicos y la semántica para los bucles de herramientas y los turnos de sistema o parciales, y añade cobertura para los casos de intercambio e historial indicados sin cambiar el almacenamiento plano ni la serialización del proveedor.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
Why this matters
Chatlas stores a flat sequence of SystemTurn, UserTurn, and AssistantTurn objects. A single user request that invokes tools can span several user/assistant turns, making transcript review, UIs, and tracing consumers reconstruct the logical exchange themselves.
Ellmer added a read-only Round abstraction in tidyverse/ellmer#1056 (59bbe9d4): each round starts with input turn(s) and includes the assistant/tool-result turns that follow. Storage remains flat.
Scope
- Design and add a public, read-only Python API that groups current history into logical conversation rounds without changing how turns are stored or submitted to providers.
- Include a clear definition for tool loops, system turns, and partial assistant turns.
- Provide an ergonomic way to retrieve all rounds and the final round.
- Ensure returned round objects preserve the original turns rather than duplicating provider state.
- Add tests for ordinary exchanges, multiple tool-result cycles, system-prompt inclusion, manually supplied history where supported, and interrupted/partial responses.
Starting points
chatlas/_chat.py:get_turns(),get_last_turn(), and partial-turn helpers.chatlas/_turn.py:SystemTurn,UserTurn,AssistantTurn, andpartial_reason.Chat.get_turns(tool_result_role="assistant")already offers display-oriented collapsing, but it is not a round API.- Ellmer reference:
git -C ../ellmer show 59bbe9d4.
Non-goals
- Do not replace the flat internal history or alter provider serialization.
- Do not add mutation APIs such as
set_rounds()without a separate design decision.
Design note
This is a public API addition. Settle names, object shape, and system-turn semantics before implementation; the ellmer behavior is a useful reference, not a requirement to mirror verbatim.
- Lenguaje dominante
- Python
- Estrellas
- 179
- Forks
- 32
- Merge medio
- 1 d 3 h
- PR fusionados (30 d)
- 10
Preparar el entorno
Este proyecto no incluye contenedor de desarrollo, Dockerfile ni guía de contribución, así que la configuración corre por tu cuenta: empieza por su README y consulta nuestra guía para la primera contribución para los pasos generales.
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de posit-dev/chatlas
-
A streaming text delta that repeats everything streamed so far is missing from the recorded turnPosiblemente ocupada @cpsievert la tomó hace 81 días. Abiertoai-triage:done Priority: Medium
Dificultad 2/5 1-3 horas Aptitud para principiantes 84/100
Los mantenedores suelen responder en 1 día
-
ai-triage:needs-review documentation
Dificultad 2/5 1-2 días Aptitud para principiantes 76/100
Los mantenedores suelen responder en 1 día
-
Dificultad 4/5 3-5 días Aptitud para principiantes 42/100
Los mantenedores suelen responder en 1 día
-
Dificultad 4/5 1-2 días Aptitud para principiantes 35/100
Los mantenedores suelen responder en 1 día
-
ai-triage:done Priority: Low
Dificultad 3/5 1-2 días Aptitud para principiantes 55/100
Los mantenedores suelen responder en 1 día
Todos los issues de posit-dev/chatlas
Issues similares
-
bot-triaged module: decompositions module: edge cases module: int overflow module: primTorch oncall: pt2 triage review
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
Los mantenedores suelen responder en 1 día
-
[TV SHOW]: Dynasty (1981)Abiertocountry:US rating:6 request-theme type:TV SHOW
Dificultad 1/5 Menos de una hora Aptitud para principiantes 65/100
LizardByte/ThemerrDB#10501 · 1 comentario ·
-
triage/confirmed
Dificultad 2/5 1-3 horas Aptitud para principiantes 77/100
agentscope-ai/agentscope#4563 ·
Los mantenedores suelen responder en 2 días
-
comp/desktop desktop/chat P3 type/bug
Dificultad 2/5 1-3 horas Aptitud para principiantes 77/100
NousResearch/hermes-agent#164451 ·
Los mantenedores suelen responder en 1 día
-
external integration integration-submission
Dificultad 2/5 1-3 horas Aptitud para principiantes 68/100
langchain-ai/docs#8426 ·
Los mantenedores suelen responder en 1 día