fix(agent): inject current datetime as ISO 8601 (was DD/MM, misread as MM/DD)#29
Merged
Merged
Conversation
…s MM/DD)
The agent's injected "Current datetime" system-data (and the {current_datetime}
template var) used %d/%m/%Y, so an LLM read e.g. 11/07/2026 as MM/DD -> Nov 7
instead of Jul 11, scheduling calendar events on the wrong day. Emit ISO 8601
(YYYY-MM-DD HH:MM) + weekday so day/month order is unambiguous.
There was a problem hiding this comment.
Sorry @gomessguii, you have reached your weekly rate limit of 500000 diff characters.
Please try again later or upgrade to continue using Sourcery
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Agente injeta a data atual como ISO 8601 (era DD/MM, LLM lia como MM/DD)
Bug: o agente recebe a data atual num bloco
system-data(Current datetime: ...) e na var de template{current_datetime}, ambos formatados como%d/%m/%Y. Uma LLM lê11/07/2026como MM/DD → 7 de novembro, em vez de 11 de julho. Resultado: pedir "agende pra amanhã" hoje (11/jul) criava evento pra 8/nov.Fix: emitir ISO 8601 (
YYYY-MM-DD HH:MM), e nosystem-dataincluir o dia da semana, pra a ordem dia/mês ser inequívoca:src/services/adk/agents/llm_agent_builder.py:626(var{current_datetime}):1017(blocosystem-datainjetado em todo agente)Descoberto testando o agendamento via Google Calendar no agente.