I’m working with an AI Agent that retrieves long URLs from a Notion database and needs to pass them along a chain of agents. However, I’m encountering an issue where the URL gets truncated due to its length, and I can’t seem to find a way to prevent this. The end of the URL appears like this: IQoJb3JpZ2luX2VjEKr%2F… (truncated for brevity).
I’ve tried setting a strict system message instructing the agent not to truncate the URL, but this hasn’t resolved the issue. Has anyone faced a similar problem? Any solutions or workarounds that could help in preserving the full URL when passing it through the workflow? Your assistance would be greatly appreciated. Thank you!
Have checked in the logs that the truncated URL is not coming from Notion rather than the agent? I know that in Notion you can set an option on the URL property of a table to truncate it. Check if you need to disable that option in Notion.
Btw, you can also try the Require Specific Output Format option of the AI Agent, when you need more strictness on the output.
You can hook up another node to specify the particular output that you want the Agent to output.
Hello. I’ve checked the Notion response format, and it returns a valid URL. I also added an OutputParser, but even with that, the link still gets truncated.