Skip to content

ReadTextFileRequest

Base classes

Name Children Inherits
BaseAgentRequest
aclientp.schema.agent_requests
Base class for all agent requests.

⋔ Inheritance diagram

graph TD
  95970861057040["agent_requests.ReadTextFileRequest"]
  95970861850336["agent_requests.BaseAgentRequest"]
  95970858197488["base.Request"]
  95970862258240["base.AnnotatedObject"]
  95970862254416["base.Schema"]
  95970851503232["main.BaseModel"]
  125067848591872["builtins.object"]
  95970861850336 --> 95970861057040
  95970858197488 --> 95970861850336
  95970862258240 --> 95970858197488
  95970862254416 --> 95970862258240
  95970851503232 --> 95970862254416
  125067848591872 --> 95970851503232

🛈 DocStrings

Bases: BaseAgentRequest

Request to read content from a text file.

Only available if the client supports the fs.readTextFile capability.

Source code in src/aclientp/schema/agent_requests.py
class ReadTextFileRequest(BaseAgentRequest):
    """Request to read content from a text file.

    Only available if the client supports the `fs.readTextFile` capability.
    """

    limit: int | None = Field(default=None, ge=0)
    """Maximum number of lines to read."""

    line: int | None = Field(default=None, ge=0)
    """Line number to start reading from (1-based)."""

    path: str
    """Absolute path to the file to read."""

limit class-attribute instance-attribute

limit: int | None = Field(default=None, ge=0)

Maximum number of lines to read.

line class-attribute instance-attribute

line: int | None = Field(default=None, ge=0)

Line number to start reading from (1-based).

path instance-attribute

path: str

Absolute path to the file to read.

:fa-brands-github: Show source on GitHub