liveBook · Manning

AI agent

As explained in Investing for Programmers

An AI agent is an artificial intelligence system that independently plans and performs multiple steps toward a specified task.

An AI agent is an artificial intelligence system that independently plans and performs multiple steps toward a specified task. In financial research, it can collect web data, analyze financial statements and news, assess sentiment, and produce a report. This turns a largely manual analytical workflow into an orchestrated process, while leaving uncertainty and validation responsibilities with the user. section 1.3.2 section 9.1.2

Useful agentic patterns include:

  • Tool use lets an agent select external APIs, libraries, or specialized services, such as stock-price retrieval or sentiment analysis, and integrate their results. section 9.1.2
  • Planning lets an agent define a goal, inspect constraints and dependencies, construct a sequence of actions, and monitor execution. section 9.1.2
  • Reflection adds a cycle of action, evaluation, and adaptation, allowing the agent to revise risk thresholds, strategies, or execution timing. section 9.1.2

A practical workflow can begin with a prompt repository and structured research process, then export findings to Notion. Frameworks add abstractions such as prompt enhancement, retrieval-augmented generation, resource access, and workflow orchestration. The implementation choice is strategic: no-code interfaces such as n8n reduce initial complexity, while code-based approaches provide more control and customization. section 9.0 section 9.3

Researching a company with LangChain

A LangChain agent can combine an LLM with Yahoo Finance news tools and answer a question such as “What happened today with Microsoft stocks?” It can also use custom data providers, extending the research workflow beyond a single prompt. section 9.3.1

Figure 9.1 A reference workflow for an AI agent
figure

Use the reference workflow to inspect how an agent connects goals, tools, intermediate steps, and results. section 9.1.2

AI agents remain fallible: they may lack context, make mistakes, or produce hallucinations. Validate important financial or tax suggestions with appropriate expertise, and avoid replacing deliberate problem-solving with repeated prompts and unexamined outputs. section 13.1

How Investing for Programmers covers it

How deep it goes
Explains planning, tool use, reflection, frameworks, and implementation choices, but defers production reliability and comprehensive validation.
Examples
Demonstrates asset research, stock-price retrieval, sentiment analysis, Microsoft news analysis, n8n workflows, and Notion exports.
What it assumes
Assumes basic LLM prompting and research familiarity while introducing agent workflows, tool coordination, frameworks, and no-code versus code choices.
What you can do after
Build structured research workflows with prompts, external tools, n8n, or LangChain, then validate their outputs cautiously.
How it connects
Connects AI agents with generative AI, large language models, retrieval-augmented generation, prompts, APIs, and financial research.

Also explained in

Compare how 33 books explain AI agent →

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Investing for Programmers. The section links point to the parts of the book it draws on.