Systems and methods for an artificial intelligence agent generating structured objects

The AI agent addresses inefficiencies in AI-assisted content generation by directly creating and managing structured objects within a user interface, improving efficiency and collaboration through direct rendering and reuse of artifacts.

US12817861B1Active Publication Date: 2026-12-01ANTHROPIC PBC
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
US19/565399
Authority / Receiving Office
US · United States
Patent Type
Patents(United States)
Current Assignee / Owner
Priority Date
2025-03-17
Filing Date
2026-03-12
Publication Date
2026-12-01
Estimated Expiration
2046-03-12

AI Technical Summary

Technical Problem

Existing AI-assisted content generation systems require significant human intervention to convert text responses into structured objects, leading to inefficiencies in creating and revising rich content formats.

Method used

An AI agent that generates structured objects directly within a user interface, allowing for the creation, editing, and sharing of artifacts such as data plots and code snippets in predefined formats, with the ability to store and reuse these objects across sessions.

Benefits of technology

Enhances the efficiency of AI-assisted content generation by enabling direct rendering and manipulation of structured objects, reducing the need for manual formatting and facilitating collaboration and reuse of artifacts.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure US12817861-D00000_ABST
    Figure US12817861-D00000_ABST
Patent Text Reader

Abstract

Embodiments described herein provide an AI agent to create structured data, which in turn is presented at a user interface (UI) section as a standalone work product. The standalone work product may be revised directly through the UI section, stored as an individual file, shared across different conversation sessions, and / or reused for generating a new work product.
Need to check novelty before this filing date? Find Prior Art

Description

CROSS REFERENCE

[0001] The instant application is a nonprovisional of and claims priority under 35 U.S.C. 119 to U.S. provisional application No. 63 / 773,387, filed Mar. 17, 2025, which is hereby expressly incorporated by reference herein in its entirety.TECHNICAL FIELD

[0002] The embodiments relate generally to machine learning systems.BACKGROUND

[0003] Artificial intelligence (AI) agents often employ a neural network based generative language model to generate an output such as in the form of a text response. The generated output may be used in other applications and workflows.SUMMARY

[0004] Embodiments provide an AI agent operated for creating a structured object in response to a task request. A first task request relating to generating one or more structured objects may be received via an interactive user interface on a user device. An output comprising a first portion corresponding to a text response and a second portion corresponding to the one or more structured objects of one or more types of formats may be generated by a neural network based language model at a server in response to the first task request. The second portion may be converted by one or more application programming interfaces (APIs) at the server into one or more structured scripts for object rendering according to the one or more types of formats. The text response and the one or more structured scripts may be transmitted to the user device that causes a display within the interactive user interface of the text response at a first user interface section and the one or more structured objects at a second user interface section independent of the first user interface section

[0005] In one embodiment, the one or more structured objects may comprise one or more of: a text document, a code snippet, a web page, an image, a diagram, a flow chart, and an interactive React component.

[0006] In one embodiment, the second portion may comprise one or more function calls to invoke the one or more APIs to format model-generated content into the one or more structured objects of the one or more types of formats.

[0007] In one embodiment, a revision request to the one or more structured objects may be received via the interactive user interface. An updated text response describing one or more revisions and one or more updated structured objects corresponding to the one or more revisions may be generated by the neural network based language model. The updated text response and the one or more updated structured objects may be transmitted to the user device that causes the display within the interactive user interface of the updated text response at the first user interface section and the one or more updated structured objects at the second user interface section.

[0008] In one embodiment, the revision request may be received via a user input directly applied at the second user interface section to interact with the one or more structured objects, or via a conversation input describing the revision request.

[0009] In one embodiment, the first user interface section may comprise a dialog format within the interactive user interface, and the second user interface section may comprise a foldable panel displayed on a side of the interactive user interface.

[0010] In one embodiment, the one or more structured objects may be exported to a local application on the user device without disrupting the one or more types of formats.

[0011] In one embodiment, the one or more structured objects created within a first conversation session may be stored at a memory of the server. At least one of the one or more structured objects may be retrieved from the memory in response to a second task request for generating a new structured object in a second conversation session.

[0012] In one embodiment, the one or more APIs for creating the one or more structured objects may be determined based on the first task request. One or more function calls to the one or more APIs may be generated by the neural network based language model. The one or more structured scripts corresponding to the one or more types of formats created by one or more applications hosted at the server may be obtained through the one or more APIs.

[0013] In one embodiment, the one or more structured scripts corresponding to the one or more types of formats may be rendered as a single output within the second user interface section.

[0014] In one embodiment, the one or more structured objects may be rendered within a security architecture comprising one or more of: a first protection layer configured to segregate the one or more structured objects from the interactive user interface, a second protection layer to separately render the one or more structured objects intended for different domains, a third protection layer to control access to the one or more structured objects.BRIEF DESCRIPTION OF THE DRAWINGS

[0015] FIG. 1 shows an application of a Large Language Model (LLM) based AI agent, according to embodiments of the present disclosure.

[0016] FIG. 2A is a simplified block diagram illustrating aspects of the LLM responding to a task request to create one or more artifacts in a dedicated workspace, according to embodiments described herein.

[0017] FIG. 2B is a simplified block diagram illustrating aspects of artifacts sharing among users and / or conversations, according to embodiments described herein.

[0018] FIGS. 3A-3B provide simplified diagrams illustrating a use case of generating and / or revising a data table through an AI agent UI, according to embodiments described herein.

[0019] FIG. 4 provides a simplified diagram illustrating a use case of generating and / or revising a code snippet through an AI agent UI, according to embodiments described herein.

[0020] FIG. 5 is a simplified diagram illustrating a computing device implementing the AI agent artifact framework described in FIGS. 1-4, according to one embodiment described herein.

[0021] FIG. 6 is a simplified diagram illustrating the neural network structure implementing the AI agent module described in FIG. 5, according to some embodiments.

[0022] FIG. 7 is a simplified block diagram of a networked system suitable for implementing the AI agent artifact generative framework described in FIGS. 1-6 and other embodiments described herein.

[0023] FIG. 8 is an example logic flow diagram illustrating a method of operating an AI agent user interface for creating a work product in response to a task request based on the framework shown in FIGS. 1-7, according to some embodiments described herein.

[0024] Embodiments of the disclosure and their advantages are best understood by referring to the detailed description that follows. It should be appreciated that like reference numerals are used to identify like elements illustrated in one or more of the figures, wherein showings therein are for purposes of illustrating embodiments of the disclosure and not for purposes of limiting the same.DETAILED DESCRIPTION

[0025] LLMs may be used to generate new data such as text across various domains, e.g., drafting emails, creating reports, creative writing, and / or the like. Significant human operations are often needed to construct a final resulting product.

[0026] For example, a writer may engage with an LLM to assist their writing. The writer may access an LLM portal via a browser application, conduct a dialogue with the LLM via the web, copy and paste LLM generated text into a separate document, and manually adjust the format and / or revision to generate a final work product. For another example, a programmer who uses an LLM to suggest code updates may similarly access the LLM portal via a browser application or a command line interface, send a coding request to the LLM via the web or the command line interface, copy and paste the LLM generated code snippet into an integrated development environment (IDE) for review and execution. For another example, a user may engage a multi-modal LLM to perform a vision-language task such as image captioning, but then may need to manually incorporate the image and the generated captions into a separate document to create a work product.

[0027] In view of the need for improving AI-assisted content generation efficiency, embodiments described herein provide an AI agent that generates structured data to be directly rendered as a structured object presented in a user interface (UI) section as a standalone work product. For example, the AI agent may, in response to a user task request, generate a text response in a conversational thread and a structured and self-contained object having a defined format (such as bullet points, chart, data plots, and / or the like) displayed in a separate UI panel independent of the conversational thread while preserving the defined format. The structured and self-contained object, referred to as an “artifact,” may be displayed, downloaded, saved, edited, shared, forwarded and / or reused while the pre-defined format is preserved.

[0028] In one embodiment, the AI agent may generate an artifact as a structured representation of an LLM output in response to the user task request. The structured representation may be internally serialized (e.g., in JavaScript Object Notation (JSON) or a similar schema) and then rendered as a structured element in the user interface. In this way, the AI agent generates a separate standalone work product that may be directly edited, stored, downloaded and / or shared as an individual file. Efficiency of AI-assisted content generation technology is thus improved, in particular for rich content generation such as React applications, HyperText Markup Language (HTML), scalable vector graphics (SVG) image, diagrams, and / or the like.

[0029] FIG. 1 illustrates an example operation of an LLM based AI agent, according to embodiments of the present disclosure. An AI agent may refer to a set of software and / or hardware that processes information from its environment and takes action to achieve specific goals such as executing a task. For example, as shown in FIG. 1, an AI agent infrastructure may comprise an AI agent client application 110 implemented on a user device 104 that is communicatively coupled to an LLM 120. The LLM 120 may be hosted at a server, a cloud service, and / or the like that is accessible by the user device via a communication network.

[0030] In one embodiment, the LLM 120 may be hosted on the user device 104. In that case, the AI agent client application 110 may be integrated with the LLM 120 on the user device 104.

[0031] In one embodiment, the AI agent client application 110 may receive a user task request 106 as a natural language input, e.g., through an AI agent UI 107. For example, as shown in FIG. 1, the user task request 106 may include a question of “can you compare the traffic pattern of this month with last month in a data plot.” The AI agent may then determine a generation mode in response to the user task request 106, e.g., pure conversational text, artifact, and / or the like. An artifact mode may include presenting generated content in a structured object formatted with different types of presentation elements, including but not limited to texts, paragraphs, bullet points, tables, charts, plots, and / or the like. The generated artifact may be directly downloaded and saved as a document file, copied and pasted into a document file while keeping the formatting of its different types of presentation elements, and / or editable within a dedicated UI panel at the AI agent client application 110. In one embodiment, a user may specify the generation mode along with the user task request 106. For example, the AI agent client application 110 may provide a user interface element for a user to select the “artifact” mode while entering the user task request 106, instead of merely generating a text presented as a conversation response within a chat interface of the AI agent client application 110.

[0032] In one embodiment, the AI agent may parse the user task request 106 to determine the generation mode. For example, the AI agent may identify the key terms from the user task request 106 such as “data plot” and determine artifact generation is to be triggered as a “data plot” analysis is entailed.

[0033] In one embodiment, the AI agent may maintain a public artifact library, and present one or more artifacts as samples to the user in response to the user task request 106. For example, upon determining that an artifact of a “data plot” may be triggered by the user task request 106, the AI agent may present sample data plots to showcase the selected artifact to be included in the generation, and / or present users different options of data plots for the user to choose, e.g., a curve data plot, a bar chart, and / or the like.

[0034] In one embodiment, the AI agent may determine whether “artifact” generation may be triggered based on various additional factors, such as, content substantiality (e.g., whether the user task request 106 may lead to an answer exceeding a predetermined threshold such as fifteen lines), content self-containment (e.g., whether the user task request 106 may lead to an answer that functions independently without requiring additional contextual information from the conversation), reusability potential (e.g., whether the user task request 106 may lead to an answer that is likely to be referenced, modified, or utilized outside the immediate conversation context), structural complexity (e.g., whether the user task request 106 benefits from specialized formatting or organization), user intent inference (e.g., whether the AI agent determines the user implicit or explicit desire for standalone content), and / or the like.

[0035] In one embodiment, the user task request 106 may be incorporated in a predefined format providing instruction (e.g., referred to as a “prompt”) to the LLM 120 how to generate an output including indicating the determined generation mode. For example, the multiple factors may be included into a system prompt that is combined with the user task request 106 to be fed to the LLM 120 for response generation.

[0036] In one embodiment, an example prompt for the LLM 120 to generate an artifact may comprise instructions to create and edit certain types of content like documents, code, and HyperText Markup Language (HTML), and / or the like. The instructions may describe how the assistant should write new content, how to update or replace specific portions of existing content, and how to handle edits made by the user. It also explains how user interactions with the content panel are communicated back to the assistant, such as when the user selects text, and / or the like.

[0037] In one embodiment, in response to the user task request 106, LLM 120 may first generate structured data for the artifact.

[0038] In response to the input prompt, the LLM 120 may in turn provide an output comprising a text portion 108, e.g., a textual description of the requested comparison, and a data plot 109 illustrating the traffic pattern in two months. The LLM 120 may present the text portion 108 and the data plot 109 at two separate UI section of the AI agent client application 110. The text portion 108 may be presented in a conversation format in response to the user task request 106 in a chat interface. The data plot 109 may be presented at a separate panel such as a standalone structured object next to the conversation thread, below a system response, or at different places within the chat interface. For another example, the artifact panel may be expanded, resized, moved, and / or controlled by a user in any other manner, e.g., via a user-draggable resize handle. The artifact panel may thus be adjusted to be presented according to a user configuration.

[0039] In one embodiment, a revision request may be received via the AI agent UI 107, e.g., to change the data range or legend. The revision request may be processed via a similar manner as that for the user task request 106, e.g., the LLM 120 may in turn generate an updated text response (e.g., similarly presented as the text response 108) and an updated data plot (e.g., similarly presented as the data plot 109).

[0040] In one embodiment, the data plot 109 may be directly edited by the user 102. For example, the user 102 may engage with the panel within which the data plot 109 is presented to add a caption, to enlarge the size of the frame, and / or the like. For example, the user 102 may directly upload structured objects, such as a PDF file and / or an image file into the artifact, e.g., the data plot 109 for editing. The uploaded files may be processed as user feedback to be sent to the LLM 120 to extract information to revise the data plot 109.

[0041] For another example, the AI agent UI 107 permits the user 102 to supply one or more binary files, such as image files or portable-document-format files, to a rendered artifact 140a at render time. The artifact runtime makes the supplied files available to the executable instructions of the artifact through a file-access interface, and the supplied files may additionally be included as input content in an artifact-originated inference request transmitted to LLM 120. In one example, the artifact renders a file-drop region within the AI agent UI 107; upon the viewing user dropping an image file into that region, the artifact transmits an inference request carrying the image file to LLM 120, receives a textual analysis of the image in response, and displays that analysis within the rendered artifact, without initiating a new conversation session.

[0042] In one embodiment, the data plot 109 may be directly reusable in a user specified format. For example, the side panel within the AI agent UI 107 at which the data plot 109 is presented may comprise a “save” option to save the data plot 109, as a scalable vector graphics (SVG) image, and / or the like; a “copy” option for the user 102 to copy the data plot 109 and paste as a whole into a different document; and / or an “email” option for the user 102 to directly forward the data plot 109 as an attachment in an electronic mail.

[0043] In one embodiment, the generated artifact, such as the data plot 109 may be saved and / or shared among different user devices operated by the same user 102. In another embodiment, generated artifacts, e.g., by different users, may be sharable among a group of authorized users, e.g., via a shared workspace. In some embodiments, the AI agent may generated artifact and deploy it to a server such that it is accessible to users outside of the development environment. In some embodiments, this may be a web application that is hosted on a web server.

[0044] In one embodiment, the generated artifacts may be stored as a library of artifacts, such that previously generated artifacts may be used as templates for new tasks. The artifact library may maintain metadata associated with each stored artifact, including artifact type identifiers, data schema definitions, visualization parameters, and contextual tags derived from the original user task request 106, and / or the like. When a new user task request 106 is received, the AI agent may perform a similarity analysis between the new request and the metadata of stored artifacts to identify candidate template artifacts. For example, a new user task request relating to comparing sales revenue of July and June may be semantically matched to previously generated artifacts of comparing sales revenue of May and April based on matching data schema structures (e.g., time-series revenue data), visualization type (e.g., comparative bar chart), and analytical operation (e.g., month-over-month comparison). Upon identifying a suitable template artifact, the AI agent may instantiate a new artifact instance by cloning the structural components of the template artifact, including layout configurations, axis definitions, legend formatting, and data binding schemas, while populating the cloned instance with new data corresponding to the current user task request. In this manner, artifact generation may leverage previously generated structured data representations to reduce computational overhead, maintain consistency in artifact presentation across related tasks, and accelerate response time by bypassing redundant structural generation processes.

[0045] In one embodiment, the data plot 109 may be stored and retrieved in a different conversation thread, e.g., by a different user, shared among different conversation sessions, and / or the like. For example, the data plot 109 may be automatically stored at a library hosted at a server with the LLM 120 such that the user 102 and / or another user who is authorized to share artifacts with the user 102 may search for and retrieve the saved data plot 109 from the library.

[0046] FIGS. 2A-2B are simplified block diagrams illustrating different embodiments of example agent architecture for generating one or more artifacts, according to embodiments described herein. As shown in FIG. 2A, the LLM 120 may respond to a user task request 106 to create one or more artifacts 140a-140n, which may in turn be presented within an AI agent UI 107 at a dedicated UI element such as a side panel.

[0047] In one embodiment, the LLM 120 may be pre-trained using a large corpus of data in different types of presentation formats, such as texts, paragraphs, bullet points, data plots, charts, tables, and / or the like to generate an output sequence of tokens representing content formatted in a certain type of presentation element in response to an input prompt comprising a request to generate an artifact. Additional details of LLM generation may be described below in relation to FIG. 6.

[0048] In one embodiment, in response to the user task request 106, an input prompt may be formed comprising the user task request 106 and specific instructions on whether and how to format an artifact output. For example, as described in relation to FIG. 1, the input prompt may comprise instructions on when to use artifacts (e.g., for substantial, self-contained content), how to structure artifact tags (opening and closing <artifact> tags), supported content types and how to select one or more types of content types for presenting generated content and their corresponding Multipurpose Internet Mail Extensions (MIME) types, and / or the like.

[0049] For example, the input prompt may indicate different types of artifacts including textual artifacts such as structured text documents, markdown files, reports, and tabular data; code artifacts including snippets, functions, classes, and complete modules in various programming languages; visualization artifacts such as scalable vector graphics (SVG) images, data plots, dynamic charts, and diagram representations; interactive web artifacts such as HTML files, CSS styling, React components, and JavaScript interfaces; structured data artifacts such as JSON objects, XML files, and data schema definitions; diagramming artifacts including flowcharts, entity-relationship diagrams, sequence diagrams, and state machines represented in formats such as Mermaid or similar markup; and / or hybrid artifacts combining multiple aforementioned types.

[0050] For another example, the input prompt may instruct the LLM 120 with examples to showcase different types of artifacts for different types of user task requests 106, e.g., a code segment when the user task request 106 relates to code generation, a chart or a table when the user task request 106 relates to data analytics, bullet points when the user task request 106 relates to information gathering, and / or the like. Based on the input prompt, the LLM 120 may determine and select one or more artifact types for the user task request 106 and generate an LLM output indicating such selected artifact types.

[0051] In one embodiment, the input prompt may include definitions of the role of the AI agent (e.g., the AI agent is acting as an illustrator for an input document, a script writer based on input corpus of background materials, and / or the like) with parameters for interacting with an application programming interface (API) (e.g., 130a-n), implementations of a command system with slash commands (e.g., “ / help,”“ / tutorial”) that trigger predefined agent behaviors, a function call of an application through the API, safety validation mechanisms to access an application via the API 130a-n, and environment detection functionality that captures working directory state, version control status, platform details, and temporal context, and / or the like for artifact generation. Various combinations of these elements may be employed to create different implementations of the AI agent, each tailored to specific use cases or environments while maintaining the core functionality of providing contextually appropriate artifact generation.

[0052] In one embodiment, the LLM 120 may comprise a Retrieval-Augmented Generation (RAG) architecture to generate an output based on a relevant context to the user task request 106. For example, in response to the user task request 106 such as “comparing the traffic pattern of this month with last month in a data plot” as shown in FIG. 1, a retriever 125 may retrieve one or more stored records, documents and / or other files containing the data relating to “traffic pattern of this month” and “traffic pattern of last month” as indicated in the user task request 106 from a database 119. The retrieved documents, data and / or other files may then be included in the input prompt to the LLM 120. For another example, the retriever 125 may retrieve documents relating to a guideline data visualization of time series data. The retrieved guideline of data visualization may thus be included as part of the input prompt to guide the LLM 120 to generate function calls for generating an artifact of data plots based on the retrieved guideline as a context.

[0053] In some embodiments, the LLM 120 may generate a function call, e.g., in a form of a Model Context Protocol (MCP) request to a search engine to perform a real time Internet search so as to retrieve the most current information available. In some embodiments, the MCPs may provide APIs to connect to third party applications to retrieve data from third party sources. In some embodiments, such as a messaging platform to retrieve message data, to a coding platform or repository service to retrieve code segments, to external databases or document storage systems to query and retrieve information, and / or the like. Additional information of incorporating function calls to one or more MCP servers may be described in relation to FIG. 7. By incorporating the retriever 125 and / or the database 119, the LLM 120 can dynamically pull in information from external data sources (such as the database 119, an Internet source, etc.), to generate responses that are up-to-date and function calls for the APIs to generate the artifacts compliant with the latest knowledge of the application.

[0054] In one embodiment, the LLM 120 may respond to an editing input to re-generate and / or update the artifacts 140a-n. For example, one training objective for LLM 120 is a string manipulation that may convert a first version of an artifact (such as a document) to an updated version of the artifact in response to a text editing input, e.g., using fewest tokens to achieve a high level of accuracy and correctness. Such string manipulation may comprise replacing a string that is identified for editing, changing formats of the artifacts, change indexing formats (e.g., line and column numbers, etc.), and / or the like.

[0055] In one embodiment, the LLM 120 may generate an LLM output according to the instructions and the user task request contained in the input prompt. The LLM output may take a form of a sequence of tokens comprising data content, metadata for artifact information, and / or the like. An example artifact output generated by LLM 120 may take a form as a structured language and / or code segment.

[0056] In one embodiment, the LLM output, as structured content, may be rendered as a separate UI component, or sent to another application for rendering. For example, the LLM output may contain functions for parsing and extracting artifacts, for identifying <artifact> tags and extracting content, for extracting metadata from tag attributes, for replacing artifact tags with a <ARTIFACTLINK> placeholder, for replacing artifact tags with code blocks for display, and / or the like. For another example, the generated artifact output may comprise an ARTIFACTLINK placeholder that may allow the markdown parser to identify artifact locations so it can insert a link in the chat to open artifacts. In one embodiment, the LLM output may further comprise one or more function calls 112a-n to connect to APIs to format a respective portion of the data content in a respective type of artifact, e.g., a table, a chart, bullet points, and / or the like. For example, the one or more function calls 112a-n may be sent to one or more APIs 130a-n corresponding to one or more applications which may in turn generate and return the corresponding artifacts 140a-n. For example, an API 130a for a charting application may generate an artifact 140a of a chart based on the function call 112a; an API 130b for a word processing application may generate an artifact 140b of one or more bullet points; and other types of APIs connected to different types of artifacts such as a presentation display application, a spreadsheet application, a coding application, an UI design application, a sketch-and-design application, and / or the like. For another example, to generate a new document artifact, a function call 112n may contain a command createDocument( ) and pass relevant LLM-generated content such as the document title, content, and formatting options to the API 130n for creating a formatted document. Depending on capabilities of the application, each artifact 140a-n may contain one or more presentation types, e.g., text and chart, chart and bullet points, and / or the like.

[0057] In some embodiments, the generated LLM output may be executed as an artifact comprising a user interactive application. For example, the LLM 120 may generate an executable code program that operates with the generate artifacts in response to a user task request 106. The generated code may include frontend components (e.g., user interface elements, event handlers, and rendering logic), backend logic (e.g., data processing routines, API endpoint definitions, and business logic implementations), and data layer configurations (e.g., database schema definitions, query templates, and data access objects). The generated artifacts may be connected and operated in conjunction with the generated code within a self-contained execution environment at the user device to form an application artifact. For example, the application artifact may be displayed within the client UI 107 as one or more interactive interfaces to the user, such as a web-based graphical user interface accessible via an embedded browser component, a RESTful API endpoint for programmatic interaction, or a command-line interface for script-based automation. In this way, the user may directly interact with the application artifact via the client UI 107, e.g., to navigate the web-based graphical user interface, to enter a command via a command-line interface, and / or the like.

[0058] In one embodiment, the generated one or more artifacts 140a-n may then be aggregated and sent, from a server that hosts the LLM 120 to the user device (e.g., 104 in FIG. 1) that runs the AI agent client application in the form of a JSON script, an HTML script, a CSS script, an SVG image, and / or other on-wire format. The delivered artifacts 140a-n may then be rendered into a structured object, the final artifact at a dedicated UI element such as a side panel within the AI agent UI 107.

[0059] In one embodiment, the generated one or more artifacts 140a-n may be stored at application servers connected to the APIs 130a-n which may be retrieved for future operations, e.g., when a similar artifact is requested to be generated.

[0060] In one embodiment, one or more of the artifacts 140a-n may be rendered at the client side (e.g., AI agent client application 110 in FIG. 1) according to different security configuration. The artifacts 140a-b may comprise a first type of inert content, such as markdown, code snippets, and / or the like, which may be rendered directly in the chat interface of the AI agent client application 110, and / or the artifact 140n may comprise a second type of rich content, such as HTML, SVG, React components, diagrams, etc., which may be rendered in a sandbox 118 of the AI agent client application 110.

[0061] In one embodiment, the one or more of the artifacts 140a-n may comprise one or more interactive UI elements, such as clickable buttons, drop-down menu, scrolling bars, and / or the like. For example, for a UI design task request, the AI agent may generate UI elements as artifacts that are rendered as an interactive webpage displayed within the client UI 107 in a standalone panel, such that the user may directly observe what the designed UI may look like. For example, in response to a user task request 106 specifying “design a login page with email and password fields,” the AI agent may generate an artifact comprising HTML markup defining form elements (e.g., input fields, labels, submit buttons), CSS stylesheets specifying layout properties (e.g., flexbox containers, grid alignments, color schemes, typography rules), and JavaScript code implementing interactive behaviors (e.g., input validation, show / hide password toggles, form submission handlers). The generated UI artifacts 140a-n may be rendered within the sandbox 118 as a fully functional webpage, allowing the user to interact with the UI elements in real-time—for instance, typing into input fields, clicking buttons, observing hover effects, and triggering validation messages. The rendered webpage artifact may mirror the visual appearance and interactive behavior of the final production UI, thereby enabling the user to evaluate design aesthetics, user experience flow, accessibility features, and responsive layout adaptations across different viewport dimensions without requiring deployment to an external hosting environment.

[0062] In one embodiment, the AI agent may adopt a security architecture for artifact rendering implemented with a plurality of protection layers. For example, the protection layers comprise an isolation mechanism implemented as a sandbox 118, such as an iframe-based sandboxing—in this way, potentially unsafe content is segregated from the chat interface and / or the rest of the AI agent client application 110, other local application 117. The protection layers may further comprise a domain isolation protocol that may implement cross-origin resource policies to render artifacts from separate origin domains or subdomains to prevent cross-site scripting vulnerabilities. The protection layers may further comprise a content restriction mechanism implementing content security policies that selectively restrict execution of scripts, application of inline styles, and loading of external resources. The protection layers may further comprise a content purification subsystem implementing sanitization procedures configured to identify and eliminate potentially malicious code patterns prior to rendering the content at the AI agent client application 110. The protection layers may further comprise an access control mechanism implementing permission models configured to restrict access of the artifacts 140a-n to local applications 117—such as browser application programming interfaces and system resources. The protection layers may further implement a communication isolation protocol implementing secure inter-frame message transmission to transmit the rendered content, such as artifact 140n via controlled message-passing mechanisms from the sandbox 118 to a local application 117, e.g., a rendered data plot may be downloaded or pasted into a document in a local word processing application.

[0063] In one embodiment, when the artifact 140n is rendered within the isolated environment such as the sandbox 118, a markdown parser may replace the <ARTIFACTLINK> contained in the delivery format (e.g., JSON, HTML, etc.) of the artifact 140n with a button that, when clicked, will open the artifact 140n within a UI element, e.g., a side panel of the AI agent client application 110.

[0064] In some embodiments, the LLM 120 may comprise a multimodal LLM that processes multiple types of input such as text, code, images, videos, and / or the like. For example, the user task request 106 may comprise a request to analyze traffic pattern from a video of monitored traffic. The vision model of the multimodal LLM may thus analyze video frames of the input video and incorporate the analytics as part of the context for LLM generation. The LLM 120 may in turn generate an LLM output comprising content and / or function calls for different applications to generate one or more artifacts in a similar manner as described above. For example, to create rich content such as HTML web pages, SVG images, and / or the like, the AI agent may respond to an input comprising a user task request (such as a text description of the webpage or layout), user-uploaded images as candidate visual elements, and / or the like, to an output token representing an HTML code snippet, which may then be sent through an API to be rendered in a browser and return a screenshot of the rendered visualization. The rendered visualization may thus be displayed at a side panel at the AI agent user interface or conversation window as a separate work product. In this way, a user may design, edit and / or interact with rich content design and observe the designed visual effect in real time, without separate compiling or rendering process.

[0065] In some embodiments, the LLM 120 may further be operated in conjunction with a generative image model (such as a diffusion model) to generate an image as part of an artifact, and / or the like. For example, the LLM 120 may be pretrained to generate a function call to an API 130a to align and format the generated image and LLM-generated text to form an illustrated article.

[0066] In one embodiment, an artifact may incorporate, format and otherwise combine two or more previously generated artifacts. For example, a user may access a previously generated artifact of an SVG image, and a previously generated artifact of an article, and request to combine the two previously generated artifacts into a single artifact. The LLM 120 may in turn generate the requested artifact using the previously generated artifacts and an input prompt based on the user task request 106.

[0067] For example, FIG. 2B further illustrates an example scenario of sharing and / or reusing artifacts across users and / or sessions. Multiple users 102a-n may send various task requests to the LLM 120 to create various artifacts 140a-n corresponding to their respective task requests in the respective conversation sessions. Each artifact generation may be similarly implemented via the architecture shown in FIG. 2A.

[0068] The artifacts 140a-n created by different users 102a-n and / or through different conversation sessions with the LLM 120 may be stored at a server hosting the LLM 120, or a cloud server to be shared and re-used by other users or in a different conversation session. For example, artifact 140a may be generated in response to a task request from user 102a, while artifact 140b may be generated in response to a task request from user 102b. The user 102a may retrieve the artifact 140b, and submit an edit 132a to edit the artifact 140b. Such edit 132a may be submitted, by user 102a, directly through a UI element presenting the artifact 140b (e.g., see 310 in FIGS. 3A-3B). Alternatively, the user 102a may enter a user request as a user utterance in a chat interface of the AI agent client application (e.g., 110 in FIG. 1), such that the LLM 120 may in turn receive the edit request and revise the artifact 140b. Similarly, the user 102b may submit an edit 132b to revise artifact 140n created in response to a task request from user 102n.

[0069] The sharing and reusing of previously stored artifacts may create a workspace of authorized user 102a-n to retrieve and share artifacts generated during various conversations, facilitating collaboration on larger projects. For example, previously generated artifacts 140a-n by the group of authorized users 102a-n may be stored at an artifact repository 219 at a server or a cloud server. The users 102a-n may access, modify, create new version of, tag, annotate, link to specific project milestones for the stored artifacts 140a-n therefore creating a joint workspace. Additionally, reusing previously stored artifacts for new generation tasks improves compute efficiency of the AI agent.

[0070] In some embodiments, the AI agent may maintain an artifact-distribution service for artifacts stored in the artifact repository 219. For example, an artifact 140a may be placed into one of at least three sharing modes: a first mode in which the artifact is accessible only to the user whose conversation produced it; a second mode in which the artifact is accessible to any user sharing an organization identifier with that user; and a third mode in which the artifact is served at a stable network address, is accessible to any requester, and may be embedded within an external web page. For an artifact in the third mode, server 720 contributes a representation of the artifact to a browsable catalog. A second user browsing the catalog may cause LLM 120 to generate a new artifact by supplying to LLM 120 the structured representation of a cataloged artifact together with a natural-language modification instruction, such that the cataloged artifact serves as a starting template and the artifact repository 219 accumulates reusable templates over time.

[0071] In one embodiment, in order for the users 102a-n to retrieve and / or share artifacts 140a-n created from different conversation sessions, the AI agent may implement session management that may save, resume, and / or maintain over time a conversation session. For example, the AI agent may store metadata associated with each artifact 140a-n created from their respective conversation session identifier, including, but not being limited to: user-agent conversation history, current working directory, active coding files, environment variables, user preferences, generated code snippets, code snippet version information, and / or the like. Sessions may be identified by unique identifiers and may be resumed by reference to these identifiers. The session management may enable long-running development tasks to be paused and resumed across multiple user interactions, preserving context and state between sessions. For example, in a coding project involving multiple threads of coding tasks, different users 102a-n (such as developers) may cross-reference and / or retrieve artifacts such as code snippets generated in different conversation sessions to access, execute and / or test a coding project.

[0072] In one embodiment, the users 102a-n may configure security levels of the artifacts 140a-n they created, and / or grant access to such artifacts to other users. For example, the user 102a may grant access to the user 102b but deny access from the user 102n to the artifact 140a. In another embodiment, the AI agent may automatically set recommended security levels of different artifacts 140a-n created by different users 102a-n, e.g., based on user affiliation, nature of the artifacts, user prior security preferences, and / or the like. For example, the AI agent may categorize users affiliated with the same domain in a sharing group to share artifacts but allow users to adjust access authorization of their artifacts based on specific needs and preferences.

[0073] In one embodiment, the security mechanism of artifacts 140a-n access may be implemented via a dual-storage mechanism. For example, persistent permissions may be stored in a project-specific configurations for long-term approved operations, while session-specific permissions are stored in memory for high-risk operations (e.g., file modification), which may not persist between sessions. In addition, each tool category may implement a specialized permission validation logic, e.g., file system operation track directory-level access with hierarchical inheritance, execution tools validate against both exact matches and command pattern recognition, and / or the like.

[0074] In one embodiment, the security mechanism of artifacts 140a-n access may be adapted in real time, based on one or more of the execution context and current working directory, previously granted permissions, tool-specific risk profiles, command complexity and potential for unintended side effects, and / or the like.

[0075] In one embodiment, the security mechanism of artifacts 140a-n access may be re-assessed periodically, intermittently, and / or on demand, through automatic path normalization for consistent security evaluation, directory tracking to prevent operations outside the intended scope, hierarchical permission pruning that cleans up redundant permissions, and / or the like. In one embodiment, to manage the security mechanism of artifacts 140a-n, the AI agent may implement persistent state management to preserve environment variables, configurations, and other state information between commands and across conversation sessions and / or created artifacts under an authorized sharable workspace. For example, the AI agent may maintain a persistent store of state information, which may include, but not being limited to: user-defined variables, environment configurations, working directory history, and frequently used commands. This persistent state may be scoped at different levels, including global state that persists across all sessions, project-specific state that applies within a specific repository, and session-specific state that applies only within a current interaction. In some implementations, the AI agent may provide commands for managing this persistent state, including commands to view, modify, or reset stored state information. In this way, the persistent state management may enable the AI agent to maintain consistency across interactions and to adapt to user preferences over time. Additionally, the persistent state management may allow sharing generated code logic and / or files across different projects (under authorized access levels) in the system and / or platform (such as a joint IDE workspace) so as to reduce computational overhead of model generation.

[0076] It is to be noted that in FIGS. 2A-2B, the LLM 120 is for illustrative purpose only, while multiple LLM(s) may be adopted by the architecture. In one embodiment, the AI agent may be equipped with an agent delegation system to delegate the task request 106 to a specific LLM agent to create a particular type of artifact, such as an LLM agent that is pretrained and / or finetuned to generate Python library files, and / or the like, or an LLM agent that is pretrained and / or finetuned to generate statistical data charts, specifically. For example, the multi-agent architecture may be implemented as a stateless agent architecture, in which each AI agent is a self-contained LLM instance with its own tool set and designed for specific search for analysis tasks. In that case, each agent can only get read-only tools for safety reasons, e.g., writeable tools are excluded.

[0077] It is further noted that in FIGS. 1 and 2A-2B, multiple AI agents may be concurrently implemented, each of which may comprise an LLM 120 that operates in a similar manner as described in FIGS. 1 and 2A-2B to maximize efficiency. For example, the concurrency mechanism may use a generator-based approach which uses JavaScript AsyncGenerator pattern for asynchronous operations. For another example, read-only tools may be run in parallel (up to a maximum number of tools in concurrency); state-modifying tools may run serially to prevent conflicts; and agent tool may internally manage its own query execution. During the concurrent / parallel operations of multiple AI agents, tool count, execution time, progress updates may be tracked. In some implementations, a sandbox may be used to enable concurrent agent execution to prevent any one of the multi-agents' actions from inflicting potential harm to the local environment. In other implementations, when one of the multiple agents may be identified as harmful (e.g., via the use of a system prompt), permission for the identified AI agent to access local files, codebase, may be deferred or declined.

[0078] FIGS. 3A-3B provide simplified diagrams illustrating a use case of generating and / or revising an artifact of a data table through an AI agent UI (e.g., similar to 107 in FIG. 1), according to embodiments described herein. Diagram 300a of FIG. 3A shows an example AI agent UI (e.g., similar to 107 in FIG. 1). The UI diagram 300a comprises a chat interface to allow a user 102 to enter a user task request 302, e.g., to “compare results” in a table. The user task request 302 may in turn be transmitted to a server-side model, e.g., LLM 120 in FIG. 2A for generation. In addition to generating a text response in the chat interface of the AI agent UI 300a, an artifact 310 of a table is created and displayed at a separate panel of the chat interface. The created artifact 310 may also be displayed at location 305 along with the text conversation, and may be downloadable as an individual file.

[0079] In one embodiment, the artifact 310 may be revised through continuous iteration of user interaction. For example, as shown in FIG. 3B, at the example UI diagram 300b, the user 102 may continuously modify the generated content, e.g., through an editing request 303 entered at the chat interface. The AI agent may then generate and / or update the artifact 310 based on the editing request 303, e.g., through a similar generation process as described in relation to FIG. 2A in response to the editing request 303, which results in a newly generated artifact 310.

[0080] In one embodiment, the artifact 310 may be directly editable via the UI panel, e.g., the user may directly edit the entries, rows and / or columns of the created table by selecting, deleting, moving, adding, modifying, and / or the like. In one embodiment, due to the possibility of editing, the AI agent may implement a version control subsystem for artifacts that enables temporal navigation of artifact evolution. In embodiments, the version control subsystem may comprise: a state-tracking mechanism recording each significant artifact modification as a discrete version; a version identifier generation algorithm assigning unique identifiers to each artifact state; a differential storage system that efficiently stores only the changes between consecutive versions rather than complete artifact copies; a version comparison engine enabling visual identification of modifications between any two selected versions; a version selection interface enabling users to navigate temporally between artifact states; and / or a version metadata repository storing contextual information such as timestamp, modification author, and modification catalyst (e.g., user request, system update). Within the same conversation session, a user may create multiple artifacts, displayed within a stacked format of panels, for example, with each artifact maintaining its independent version history. For example, a user may create an artifact of a table for comparing sales data, and a second artifact of a pie chart for comparing sales data of different categories within the same conversation, with both artifacts maintaining discrete version histories accessible through the version control subsystem.

[0081] In one embodiment, the AI agent may implement specialized workflows for controlling different versions of generated artifacts, e.g., a generated artifact may be updated and / or revised through multiple iterations with user revision requests. For example, when the AI agent generates an updated version of an artifact, the updated version may by default overwrite a prior version. Or alternatively, the prior version of generated artifact may be stored with a timestamp, a session identifier and a version number for later retrieval. With the multiple versions of generated artifacts associated with the same user request or same session, the AI agent may commit preparation workflows that analyze changes, suggest appropriate commit messages, and verify that tests pass before committing to a particular version; pull request workflows that prepare descriptions, identify reviewers, and track status; merge conflict resolution workflows that analyze conflicts, suggest resolutions, and apply fixes; and code review workflows that analyze proposed changes and provide feedback. The AI agent may maintain awareness of the repository state, branch structure, and commit history to inform these operations. In some implementations, the system may learn from past version control operations to improve the quality of suggestions for future operations.

[0082] In one embodiment, in response to the editing request 303, rather than directly applying changes to the artifact 310, the AI agent may choose to apply them as “Suggestions” that the user can approve / dismiss.

[0083] FIG. 4 provides a simplified diagram illustrating a use case of generating and / or revising a code snippet through an AI agent UI 400 (e.g., similar to 107 in FIG. 1), according to embodiments described herein. As shown at AI agent UI 400 of FIG. 4, in response to a user task request 402 to “write code for a web crawler in Python,” the AI agent may create a Python code snippet as an artifact 410 displayed at a side panel of the AI agent UI 400. For example, the AI agent may invoke an external coding platform via an MCP call to retrieve sample code relevant to the user task request 402. The MCP call may include a structured request payload specifying the programming language (e.g., Python), the functional domain (e.g., web crawling), and optional parameters such as target Python library, coding style preferences (e.g., object-oriented, functional), and complexity level (e.g., beginner, advanced), and / or the like. The external coding platform may respond with one or more sample code templates, code snippets from public repositories, or reference implementations that match the specified criteria. Upon receiving the MCP response, the AI agent may parse the retrieved sample code to extract structural patterns, import statements, function signatures, and implementation logic. The AI agent may then feed the extracted code patterns, along with the original user task request 402, to the LLM 120 as contextual grounding for code generation. The generated code segment may be sent to the AI agent client application 110 as a Python file to be presented as an artifact 410 at a standalone element . . . .

[0084] In one embodiment, the AI agent may also generate a text response 404 describing how the code segment works. For example, while the LLM 120 generates the Python code segment as described above, the LLM 120 may generate a text response 404 explaining the code segment, such as the functions of key functions in the code segment, e.g., “is_valid_url,”“get_all_links,”“crawl,” and / or the like. The text response 404 may be separately displayed from the code segment artifact 410, as a conversation response in a conversation format within the Agent UI 400.

[0085] In one embodiment, the user may enter a revision request 403 at the AI agent UI 400. The AI agent may subsequently update or re-generate the artifact 410 of the code segment, following a similar generation process as described above.

[0086] In one embodiment, because the artifact 410 of code segment is displayed as a standalone element, the Python code segment, e.g., as a Python code file, may be directly downloaded to a computing environment, forwarded as an attachment in an email, uploaded to a cloud storage system, incorporated into a software development environment, and / or may be shared with another user working on a software development project. For example, a user may engage with a “copy” button on the display panel of the artifact 410 to copy the code and then paste the code into an integrated development environment (IDE) window.Computer and Network Environment

[0087] FIG. 5 is a simplified diagram illustrating a computing device implementing the AI agent framework described in FIGS. 1-4, according to one embodiment described herein. It is to be understood that computing device 500 is shown to be one device for illustrative purpose only, computing device 500 may be implemented as a stand-alone subsystem, a distributed system comprising multiple devices, a board added to a computing device, and / or as a virtual machine. For example, the user device 104, and / or server hosting the LLM 120 may be implemented by one or more computing devices 500.

[0088] As shown in FIG. 5, computing device 500 includes a processor 510 coupled to memory 520. Operation of computing device 500 is controlled by processor 510. And although computing device 500 is shown with only one processor 510, it is understood that processor 510 may be representative of one or more central processing units, multi-core processors, microprocessors, microcontrollers, digital signal processors, field programmable gate arrays (FPGAs), application specific integrated circuits (ASICs), graphics processing units (GPUs) and / or the like in computing device 500.

[0089] Memory 520 may be used to store software executed by computing device 500 and / or one or more data structures used during operation of computing device 500. Memory 520 may include one or more types of machine-readable media. Some common forms of machine-readable media may include floppy disk, flexible disk, hard disk, magnetic tape, any other magnetic medium, CD-ROM, any other optical medium, punch cards, paper tape, any other physical medium with patterns of holes, RAM, PROM, EPROM, FLASH-EPROM, any other memory chip or cartridge, and / or any other medium from which a processor or computer is adapted to read.

[0090] Processor 510 and / or memory 520 may be arranged in any suitable physical arrangement. In some embodiments, processor 510 and / or memory 520 may be implemented on the same board, in a same package (e.g., system-in-package), on the same chip (e.g., system-on-chip), and / or the like. In some embodiments, processor 510 and / or memory 520 may include distributed, virtualized, and / or containerized computing resources. Consistent with such embodiments, processor 510 and / or memory 520 may be located in one or more data centers and / or cloud computing facilities.

[0091] In another embodiment, processor 510 may comprise multiple microprocessors and / or memory 520 may comprise multiple registers and / or other memory elements such that processor 510 and / or memory 520 may be arranged in the form of a hardware-based neural network, as further described in FIG. 6.

[0092] In some examples, memory 520 may include non-transitory, tangible, machine readable media that includes executable code that when run by one or more processors (e.g., processor 510) may cause the one or more processors to perform the methods described in further detail herein. For example, as shown, memory 520 includes instructions for AI agent module 730 that may be used to implement and / or emulate the systems and models, and / or to implement any of the methods described further herein. AI agent module 730 may receive input 540 such as an input training dataset (e.g., text dataset) via the data interface 515 and generate an output 550 which may be an artifact output.

[0093] The data interface 515 may comprise a communication interface, a user interface (such as a voice input interface, a graphical user interface, and / or the like). For example, the computing device 500 may receive the input 540 (such as a training dataset, previously stored artifacts, etc.) from a networked database via a communication interface. Or the computing device 500 may receive the input 540, such as a user task request (e.g., 106 in FIG. 1), from a user via the user interface.

[0094] In some embodiments, the AI agent module 730 may comprise a server application and a client application (e.g., similar to AI agent client application 110 in FIG. 1). The AI agent module 730 is configured to conduct a conversation with a user by providing an output to a user utterance. The AI agent module 730 may further include an LLM submodule 531 (e.g., similar to LLM 120 in FIGS. 2A-2B), an API submodule 532 (e.g., similar to APIs 130a-n in FIG. 2A), repository submodule 533 (e.g., similar to 219 in FIG. 2B for storing generated artifacts), a visualization submodule 534 (e.g., for rendering the generated artifacts at chat interface 116 or a sandbox 118 as shown in FIG. 2A).

[0095] Some examples of computing devices, such as computing device 500 may include non-transitory, tangible, machine readable media that include executable code that when run by one or more processors (e.g., processor 510) may cause the one or more processors to perform the processes of method. Some common forms of machine-readable media that may include the processes of method are, for example, floppy disk, flexible disk, hard disk, magnetic tape, any other magnetic medium, CD-ROM, any other optical medium, punch cards, paper tape, any other physical medium with patterns of holes, RAM, PROM, EPROM, FLASH-EPROM, any other memory chip or cartridge, and / or any other medium from which a processor or computer is adapted to read.

[0096] FIG. 6 is a simplified diagram illustrating the neural network structure (e.g., LLM 120) implementing the AI agent module 730 described in FIG. 5, according to some embodiments. In some embodiments, the AI agent module 730 and / or one or more of its submodules 531-534 may be implemented at least partially via an artificial neural network structure shown in FIG. 6. The neural network comprises a computing system that is built on a collection of connected units or nodes, referred to as neurons (e.g., 744, 745, 746). Neurons are often connected by edges, and an adjustable weight (e.g., 751, 752) is often associated with the edge. The neurons are often aggregated into layers such that different layers may perform different transformations on the respective input and output transformed input data into the next layer.

[0097] For example, the neural network architecture may comprise an input layer 741, one or more hidden layers 742 and an output layer 743. Each layer may comprise a plurality of neurons, and neurons between layers are interconnected according to a specific topology of the neural network topology. The input layer 741 receives the input data (e.g., 540 in FIG. 5), such as an input sequence of tokens representing a task request. The number of nodes (neurons) in the input layer 741 may be determined by the dimensionality of the input data (e.g., the length of a vector of an input sequence of task request). Each node in the input layer represents a feature or attribute of the input.

[0098] The hidden layers 742 are intermediate layers between the input and output layers of a neural network. It is noted that two hidden layers 742 are shown in FIG. 6 for illustrative purpose only, and any number of hidden layers may be utilized in a neural network structure. Hidden layers 742 may extract and transform the input data through a series of weighted computations and activation functions.

[0099] For example, as discussed in FIG. 5, the AI agent module 730 receives an input 540 of task request and transforms the input into an output 550 of an artifact. To perform the transformation, each neuron receives input signals, performs a weighted sum of the inputs according to weights assigned to each connection (e.g., 751, 752), and then applies an activation function (e.g., 461, 762, etc.) associated with the respective neuron to the result. The output of the activation function is passed to the next layer of neurons or serves as the final output of the network. The activation function may be the same or different across different layers. Example activation functions include but not limited to Sigmoid, hyperbolic tangent, Rectified Linear Unit (ReLU), Leaky ReLU, Softmax, and / or the like. In this way, after a number of hidden layers, input data received at the input layer 741 is transformed into rather different values indicative data characteristics corresponding to a task that the neural network structure has been designed to perform.

[0100] The output layer 743 is the final layer of the neural network structure. It produces the network output or prediction based on the computations performed in the preceding layers (e.g., 741, 742). The number of nodes in the output layer depends on the nature of the task being addressed. For example, in a binary classification problem, the output layer may consist of a single node representing the probability of belonging to one class. In a multi-class classification problem, the output layer may have multiple nodes, each representing the probability of belonging to a specific class.

[0101] Therefore, the AI agent module 730 and / or one or more of its submodules 531-534 may comprise the transformative neural network structure of layers of neurons, and weights and activation functions describing the non-linear transformation at each neuron. Such a neural network structure is often implemented on one or more hardware processors 510, such as a graphics processing unit (GPU). An example neural network may be a Transformer-based LLM, and / or the like.

[0102] In one embodiment, the AI agent module 730 and its submodules 531-534 may comprise one or more LLMs built upon a Transformer architecture. For example, the Transformer architecture comprises multiple layers, each consisting of self-attention and feedforward neural networks. The self-attention layer transforms a set of input tokens (such as words) into different weights assigned to each token, capturing dependencies and relationships among tokens. The feedforward layers then transform the input tokens, based on the attention weights, into a high-dimensional embedding of the tokens, capturing various linguistic features and relationships among the tokens. The self-attention and feed-forward operations are iteratively performed through multiple layers of self-attention and feedforward layers, thereby generating an output based on the context of the input tokens. One forward pass for an input token to be processed through the multiple layers to generate an output in a Transformer architecture often entails hundreds of teraflops (trillions of floating-point operations) of computation.

[0103] For example, the Transformer-based architecture may process an input sequence of tokens (e.g., letters, symbols, numbers, signs, words, etc.) using its encoder-decoder architecture (for tasks such as machine translation, etc.) or just the encoder (for classification tasks) or decoder (for generation-only tasks). First, the input sequence may be tokenized and converted into embeddings, which are dense numerical representations, e.g., vectors of values. Positional encodings are added to these embeddings to provide information about the order of tokens.

[0104] The Transformer encoder usually consists of multiple layers, each of which may process the input using a multi-head self-attention mechanism to capture relationships between tokens and a feed-forward network to transform the information, resulting in encoded representations of the input sequence of tokens.

[0105] For example, the multi-head self-attention mechanism at each Transformer layer within the Transformer encoder of an LLM may project input embeddings at the layer into three different embedding spaces using weight matrices, referred to as Query (Q) representing what a token wants to attend to, Key (K) representing what this token offers as information and Value (V) representing the actual information carried by the token. The Q K, V matrices contain tunable weights of a Transformer-based language model that are updated during training. Then, the attention mechanism computes attention scores between all tokens in the input sequence using the Q, K and V matrices. The resulting attention scores are then used to generate encoded representations of the input sequence of tokens.

[0106] Similarly, the Transformer decoder may comprise a symmetric structure with the encoder, consisting of multiple layers, each of which may comprise a multi-head self-attention mechanism. The decoder may start with a special start token and use the multi-head self-attention mechanism, augmented with encoder-decoder attention to focus on relevant parts of the decoder input. The decoder may generate output tokens one by one, with each step using the previously generated tokens as part of the input and updated attention weights. Finally, the decoder may comprise a linear layer and softmax function to predict probabilities for the next token in the sequence, selecting the most likely one to continue the output. This process repeats until a special end token is generated or a length limit is reached.

[0107] The generated sequence of tokens may jointly represent an output. For example, a Transformer-based LLM (such as LLM 120) may receive a natural language input (such as a question) and generate a natural language output (such as an answer to the question).

[0108] In one embodiment, the AI agent module 730 and its submodules 531-534 may be implemented by hardware, software and / or a combination thereof. For example, the AI agent module 730 and its submodules 531-534 may comprise a specific neural network structure implemented and run on various hardware platforms 760, such as but not limited to CPUs (central processing units), GPUs (graphics processing units), FPGAs (field-programmable gate arrays), Application-Specific Integrated Circuits (ASICs), dedicated AI accelerators like TPUs (tensor processing units), and specialized hardware accelerators designed specifically for the neural network computations described herein, and / or the like. Example specific hardware for neural network structures may include, but not limited to Google Edge TPU, Deep Learning Accelerator (DLA), NVIDIA AI-focused GPUs, and / or the like. The hardware 760 used to implement the neural network structure is specifically configured based on factors such as the complexity of the neural network, the scale of the tasks (e.g., training time, input data scale, size of training dataset, etc.), and the desired performance.

[0109] For example, to deploy the AI agent module 730 and its submodules 531-534 and / or any other neural network models such as LLM 120 described in FIG. 1-2B onto hardware platform 760, the neural network based modules 730 and its submodules 531-534 may be optimized for deployment by converting it to a suitable format, such as ONNX or TensorRT, to improve performance and compatibility. Next, depending on the size and workload requirements for modules 730 and its submodules 531-534, hardware types may be chosen for deployment, e.g., processing capacity, GPU memory size, and / or the like. Frameworks and drivers for the chosen hardware 760 may thus be installed, such as PyTorch, TensorFlow, or CUDA, to support the hardware platform 760. Then, weights and parameters of the AI agent module 730 and its submodules 531-534 may be loaded to the hardware 760. For large-scale deployments (e.g., with billions of weights for example), distributed computing frameworks may be used to handle model partitioning across multiple devices, e.g., hardware processors such as GPUs may be distributed on multiple devices, each handling a portion of weights of the model and therefore would undertake a portion of computational workload. In some embodiments, the AI agent module 730 and its submodules 531-534 may be deployed as a service, then they may be integrated with an API endpoint, using tools like Flask, FastAPI, or a cloud platform serverless services, and is accessible by a remote user via a network.

[0110] In another embodiment, some or all of layers 741, 742, 743 and / or neurons 742, 745, 746, and operations there between such as activations 461, 762, and / or the like, of the AI agent module 730 and its submodules 531-534 may be realized via one or more ASICs. For example, each neuron 742, 745 and 746 may be a hardware ASIC comprising a register, a microprocessor, and / or an input / output interface. For another example, operations among the neurons and layers may be implemented through an ASIC TPU. For yet another example, some operations among the neurons and layers such as a softmax operation, an activation function (such as a rectified linear unit (ReLU), sigmoid linear unit (SiLU), and / or the like) may be implemented by one or more ASICs.

[0111] For example, the AI agent module 730 may generate, by at least one ASIC (such as a TPU, etc.) performing a multiplicative and / or accumulative operation for a neural network language model, a next token based at least in part on previously generated tokens, and in turn generate a natural language output representing the next-step action combining a sequence of generated tokens.

[0112] In one embodiment, the neural network based AI agent module 730 and one or more of its submodules 531-534 may be trained by iteratively updating the underlying parameters (e.g., weights 751, 752, etc., bias parameters and / or coefficients in the activation functions 461, 762 associated with neurons) of the neural network based on the loss. For example, during forward propagation, the training data such as text data are fed into the neural network. The data flows through the network layers 741, 742, with each layer performing computations based on its weights, biases, and activation functions until the output layer 743 produces the network output 550. In some embodiments, output layer 743 produces an intermediate output on which the network output 550 is based.

[0113] The output generated by the output layer 743 is compared to the expected output (e.g., a “ground-truth” such as the corresponding answer to a training question) from the training data, to compute a loss function that measures the discrepancy between the predicted output and the expected output. For example, the loss function may be cross entropy, minimum mean squared error (MMSE), and / or the like. Given the loss, the negative gradient of the loss function is computed with respect to each weight of each layer individually. Such negative gradient is computed one layer at a time, iteratively backward from the last layer 743 to the input layer 741 of the neural network. These gradients quantify the sensitivity of the network output to changes in the parameters. The chain rule of calculus is applied to efficiently calculate these gradients by propagating the gradients backward from the output layer 743 to the input layer 741.

[0114] In one embodiment, the neural network based AI agent module 730 and one or more of its submodules 531-534 may be trained using policy gradient methods, also referred to as “reinforcement learning” methods. For example, instead of computing a loss based on a training output generated via a forward propagation of training data, the “policy” of the neural network model, which is a mapping from an input of the current states or observations of an environment the neural network model is operated at, to an output of action. Specifically, at each time step, a reward is allocated to an output of action generated by the neural network model. The gradients of the expected cumulative reward with respect to the neural network parameters are estimated based on the output of action, the current states of observations of the environment, and / or the like. These gradients guide the update of the policy parameters using gradient descent methods like stochastic gradient descent (SGD) or Adam. In this way, as the “policy” parameters of the neural network model may be iteratively updated while generating an output action as time progresses, the boundaries between training and inference are often less distinct compared to supervised learning—in other words, backward propagation and forward propagation may occur for both “training” and “inference” stages of the neural network mode.

[0115] In some embodiments, AI agent module 730 and its submodules 531-534 may be housed at a centralized server (e.g., computing device 500) or one or more distributed servers. For example, one or more AI agent module 730 and its submodules 531-534 may be housed at external server(s). The different modules may be communicatively coupled by building one or more connections through application programming interfaces (APIs) for each respective module. Additional details of function call through MCP servers may be discussed in FIG. 7.

[0116] During a backward pass, parameters of the neural network are updated backwardly from the last layer to the input layer (backpropagation) based on the computed negative gradient using an optimization algorithm to minimize the loss. The backpropagation from the last layer 743 to the input layer 741 may be conducted for a number of training samples in a number of iterative training epochs. In this way, parameters of the neural network may be gradually updated in a direction to result in a lesser or minimized loss, indicating the neural network has been trained to generate a predicted output value closer to the target output value with improved prediction accuracy. Training may continue until a stopping criterion is met, such as reaching a maximum number of epochs or achieving satisfactory performance on the validation data. At this point, the trained network can be used to make predictions on new, unseen data, such as generating an artifact in response to an unseen request.

[0117] Neural network parameters may be trained over multiple stages. For example, initial training (e.g., pre-training) may be performed on one set of training data, and then an additional training stage (e.g., fine-tuning) may be performed using a different set of training data. In some embodiments, all or a portion of parameters of one or more neural-network model being used together may be frozen, such that the “frozen” parameters are not updated during that training phase. This may allow, for example, a smaller subset of the parameters to be trained without the computing cost of updating all of the parameters.

[0118] In some implementations, to improve the computational efficiency of training a neural network model, “training” a neural network model such as an LLM may sometimes be carried out by updating the input prompt, e.g., the instruction to teach an LLM how to perform a certain task. For example, while the parameters of the LLM may be frozen, a set of tunable prompt parameters and / or embeddings that are usually appended to an input to the LLM may be updated based on a training loss during a backward pass. For another example, instead of tuning any parameter during a backward pass, input prompts, instructions, or input formats may be updated to influence their output or behavior. Such prompt designs may range from simple keyword prompts to more sophisticated templates or examples tailored to specific tasks or domains.

[0119] In general, the training and / or finetuning of an LLM can be computationally extensive. For example, a multimodal LLM may have over several hundred billion parameters, and a single forward pass using an input of a short sequence can involve hundreds of teraflops (trillions of floating-point operations) of computation. Training such a model requires immense computational resources, including powerful GPUs or TPUs and significant memory capacity. Additionally, during training, multiple forward and backward passes through the network are performed for each batch of data (e.g., thousands of training samples), further adding to the computational load.

[0120] In general, the training process transforms the neural network into an “updated” trained neural network with updated parameters such as weights, activation functions, and biases. The trained neural network thus improves neural network technology in AI agents.

[0121] FIG. 7 is a simplified diagram illustrating an exemplary AI agent infrastructure 700 responding to the user task request 106 from the AI agent client application 110 described in FIG. 1, according to embodiments of the present disclosure. Exemplary devices and servers shown in FIG. 7 may include device, stand-alone, and enterprise-class servers which may be similar to a computing device 500 described in FIG. 5. It can be appreciated that the devices and / or servers illustrated in FIG. 7 may be deployed in other ways and that the operations performed, and / or the services provided by such devices and / or servers may be combined or separated for a given embodiment and may be performed by a greater number or fewer number of devices and / or servers. One or more devices and / or servers may be operated and / or maintained by the same or different entities.

[0122] In one embodiment, the user device 104 may host the AI agent client application 110 which may forward an input prompt 712 comprising a user query (e.g., similar to the user task request 106 in FIG. 1) and / or any local context information to the server 720, which can be an inference server hosting the LLM 120, e.g., via a network interface 717. The network interface component 717 may include a DSL (e.g., Digital Subscriber Line) modem, a PSTN (Public Switched Telephone Network) modem, an Ethernet device, a broadband device, a satellite device and / or various other types of wired and / or wireless network communication devices including microwave, radio frequency, infrared, Bluetooth, and near field communication devices.

[0123] The server 720 may further host one or more databases 728 storing a variety of user data, model data, and / or the like. For example, the databases 728 may comprise the artifact repository 219 as shown FIG. 2B.

[0124] In one embodiment, once the server 720 receives the input prompt 712 from the user device 104, the LLM 120 may analyze the user task request and determine what actions are needed. For example, for many queries or task requests, the LLM 120 may respond directly using its trained knowledge, and / or retrieved context from a RAG setup (e.g., similar to retriever 125 in FIG. 2A).

[0125] In one embodiment, the server 720 may host APIs 130 (e.g., similar to APIs 130a-n in FIG. 2A) to one or more applications hosted at the server 720. As described in relation to FIG. 2A, the LLM 120 may generate function calls to the APIs 130 to generate one or more artifacts. For example, the API 130 may connect to applications contained by the AI agent, such as a word processing application, a spreadsheet application, a coding application, and / or the like.

[0126] In one embodiment, for queries requiring external data or actions, the server 720 may decide which tools to invoke. For example, a “tool” may refer to a function or capability that a model can invoke to perform specific actions beyond text generation, such as searching the web, performing calculations, querying databases, executing code, retrieving real-time information, interacting with external APIs, and / or the like. A tool may be defined as a JSON schema that describes a function name—what the tool is called, description—what it does and parameters—what inputs it accepts (with types and descriptions). This JSON schema may be combined into an input to the LLM. In response to an input that involves a tool, the model outputs a structured tool call request with the function name and arguments. The calling system then executes the actual function and returns results back to the model.

[0127] For example, some tools may be built directly into the inference infrastructure, such as web search capabilities, etc. The server 720 may generate an input comprising the JSON schema to the LLM 120, which in turn derives structured tool calls 712a-b from the input prompt 712, e.g., to a web server 745 to perform a web search, or to other tool servers 746. Execution results 713a-b are thus passed back to the server 720 such that the LLM 120 may incorporate these results to generate a final response 722.

[0128] In one embodiment, some tools may only be provided through external Model Context Protocol (MCP) servers, which are separate services that expose specific functionalities. For example, an MCP server for a development platform service may provide tools for searching repositories or creating issues, while a database MCP server may offer query execution capabilities. Each MCP server is a standalone service that the server 720 may call as needed, and there may be multiple different MCP servers 730a-n involved in answering a single query.

[0129] For example, the server 720 may send structured JSON requests 714a-n to the specific MCP servers 730a-n, which then interact with their respective data sources 740a-n via requests 716a-n—such as cloud database(s) 740a, external tools 740b, APIs 740n, and / or the like. These MCP servers 730a-n may process the requests 714a-n, retrieve the data 717a-n, and return structured results 715a-n back to the server 720. The server 720 can make multiple tool calls in sequence or parallel, gathering information from various sources as needed to fully address the user query.

[0130] In one embodiment, the input prompt 712 may specify, or instruct the LLM 120 to generate an artifact of a type that is not supported by the local APIs 130 at the server 720, e.g., an interface design, a circuit design, an architecture design work product in vectorized format, and / or the like. In that case, the server 720 may send a structured JSON request 714n to a corresponding MCP server 730n as described above, to connect to an API 740n specifically for the particular type of artifact. For instance, the structured JSON request 714n may serve as a MCP call to invoke a circuit-design API, specifying component types, connectivity constraints, layout rules, and / or the like. The API 740n may then return a machine-readable circuit description in a designated computer-aided design (CAD) format (e.g., Verilog or SPICE), which is converted at the server 720 into a rendering format, e.g., JSON, HTML, SVG, etc., and sent to the user device 104 for rendering as an artifact.

[0131] For another example, the server 720 may provide an isolated code-execution environment, such as a container or a virtual machine, that is coupled to LLM 120. Rather than emitting the structured representation of an artifact directly, the LLM 120 may provide source code into the code-execution environment, and the code-execution environment executes that source code to produce one or more binary output files, including without limitation word-processing documents, spreadsheet workbooks, presentation decks, and portable-document-format files. Server 720 may maintain a library of pre-authored instruction sets, each instruction set directed to a particular output format or domain, and expose that library to LLM 120 as readable files within the code-execution environment; LLM 120 reads one or more instruction sets before emitting code for the corresponding format. The working directory of the code-execution environment resets between task requests, and a separate persistent output directory surfaces produced files to the user device 104 through the AI agent UI 107.

[0132] As results flow back from web server 745, tool servers 746 and MCP servers 730a-n, the server 720 may process and synthesize the results within a context window. The context window may contain part of or the entire conversation history including the original query, all tool calls made, the results returned. For example, the context window may comprise conversation transcripts associated with the user task request 106 shown in FIG. 1, any system instructions to generate one or more particular types of artifacts and / or execution results from last inference, and / or the like.

[0133] The server 720 may then use this accumulated context to formulate the final response 722, which can be a comprehensive response that addresses the input prompt 712 corresponding to the user task request 106. Once the server 720 has gathered sufficient information and completed its reasoning, the inference server streams the final response back to the user device 104 via Server-Sent Events (SSE), allowing the AI agent client application 110 to display the answer progressively as it is generated.

[0134] In some embodiments, one or more inference requests may be submitted via an artifact 140a executing within the AI agent UI 107 at the user device 104 at render time, to the LLM 120 at server 720. For example, a user may directly submit a request to view, reuse, edit, and / or other operation with the artifact 140a via the AI agent UI 107. The artifact 140a runtime exposes a client interface, callable from the executable instructions of the artifact, that marshals an inference request, attaches authentication credentials belonging to the user currently viewing the rendered artifact, transmits the request to server 720, and returns the resulting completion to the calling artifact code. Each individual artifact, once generated and placed into the artifact repository 219, may thereby be used to perform an unbounded number of further inferences on behalf of the user.

[0135] In some embodiments, an inference request originated by a rendered artifact as described above includes one or more tool-use definitions, and LLM 120, while servicing that request, emits tool calls directed to MCP servers 730a-n, to web server 745, or to tool servers 746. In contrast to the server-side tool invocation described above with respect to FIG. 7, in which server 720 invokes tools during initial generation of the artifact, tool invocation in this embodiment occurs at render time, at the direction of the already-rendered artifact, and on behalf of the viewing user. Before the first invocation of a given tool on behalf of a given viewing user, the AI agent UI 107 presents a permission prompt identifying the tool, the MCP server that provides it, and the category of data the tool will access, and proceeds only upon an affirmative response. An administrator of an organization to which viewing users belong may enable or disable individual tools or individual MCP servers for artifacts rendered within that organization. Server 720 may record an audit log of tool invocations performed on behalf of each viewing user.

[0136] In some embodiments, the server 720 may expose a persistent storage interface to the executable instructions of an artifact 140a. The storage interface may permit the artifact to write and subsequently read key-value pairs against a backing store implemented, for example, atop databases 728 or as a separate persistent store coupled to server 720. Data written through the storage interface survives across render sessions, across browser reloads at user device 104, and across different user devices. The storage interface may support a first scope in which a stored value is keyed on the tuple of artifact identifier, viewing-user identifier, and application-supplied key, such that each viewing user maintains a private data region within the same artifact, and a second scope in which a stored value is keyed on the tuple of artifact identifier and application-supplied key alone, such that the stored value is shared across all viewing users of the artifact subject to a write policy. Server 720 may enforce per-artifact and per-user storage quotas on the storage interface. In one embodiment, the server 720 may store artifacts generated by different users in separated and secure data spaces.

[0137] In one embodiment, the workflow to generate a certain type of artifact, e.g., a complicated data structure or a combination of hybrid data objects of a workbook, spreadsheet, etc., may be saved as a user-created workflow instruction and / or specification, which may be reused when a similar artifact may be repeatedly generated.Example Workflows

[0138] FIG. 8 is an example logic flow diagram illustrating a method of operating an AI agent user interface for creating a work product in response to a task request based on the framework shown in FIGS. 1-7, according to some embodiments described herein. One or more of the processes of method 800 may be implemented, at least in part, in the form of executable code stored on non-transitory, tangible, machine-readable media that when run by one or more processors may cause the one or more processors to perform one or more of the processes. In some embodiments, method 800 corresponds to the operation of the AI agent module 730 (e.g., FIGS. 5-6) that generates artifacts in a conversation with a user.

[0139] In some embodiments, method 800 is performed by a system such as computing device 500, server 720, or another device or combination of devices. Inputs (e.g., user task request 106) may be received via a data interface such as data interface 515, network interface 717, or via a data interface that is integrated with a device.

[0140] As illustrated, the method 800 includes a number of enumerated steps, but aspects of the method 800 may include additional steps before, after, and in between the enumerated steps. In some aspects, one or more of the enumerated steps may be omitted or performed in a different order.

[0141] At step 802, a user interface of an interactive user interface (e.g., AI agent UI 107 in FIG. 1, 300a-b in FIGS. 3A-3B) may receive a first task request (e.g., 106 in FIG. 1, 302 in FIG. 3A) of generating one or more structured objects (e.g., artifact of data plot 109 in FIG. 1, or other types of artifacts such as document, table, etc.) according to one or more user queries (e.g., “compare traffic pattern” in “data plot” as shown in FIG. 1, etc.) contained in the first task request. For example, the one or more structured objects comprise one or more of: a text document, a code snippet, a web page, an image, a diagram, a flow chart, and an interactive React component (e.g., reusable UI widgets such as clicks, hovering, typing, etc.).

[0142] At step 804, a neural network based language model (e.g., LLM 120 in FIGS. 1 and 2A) may generate a text response (e.g., similar to 108 in FIG. 1) and the one or more structured objects (e.g., similar to 109 in FIG. 1) corresponding to one or more types of formats in response to the one or more user queries. For example, the AI agent may determine one or more APIs (e.g., similar to 130a-n in FIG. 2A) of one or more applications for creating the one or more structured objects based on the first task request. The neural network based language model may generate one or more function calls (e.g., similar to 112a-n in FIG. 2A) to one or more APIs (e.g., similar to 130a-n in FIG. 2A) of the one or more applications, e.g., a word processing application, a spreadsheet application, an image editing application, a chart or plot application, and / or the like. The function calls may invoke the one or more APIs to format model-generated content into the one or more structured objects of the one or more types of formats.

[0143] The one or more APIs may then convert the function calls into one or more structured scripts (e.g., JSON, HTML, etc.) for object rendering according to the one or more types of formats. The AI agent may then obtain, through the APIs, the one or more structured objects (e.g., similar to artifacts 140a-n in FIG. 2A) corresponding to the one or more types of formats created by the one or more computer applications.

[0144] At step 806, the AI agent may cause a display within the interactive user interface (e.g., similar to AI agent UI 107 in FIG. 1, 300a-b of FIGS. 3A-3B) the text response at a first user interface section (e.g., similar to the text response 108 presented as a chat response in FIG. 1, etc.) and the one or more structured objects at a second user interface section (e.g., similar to the data plot 109 presented at a side UI panel in FIG. 1, 310 in FIGS. 3A-3B) independent of the first user interface section. For example, the second user interface section comprises a foldable panel displayed on a side of the interactive user interface. For another example, the one or more structured objects are exportable via a communication application in a user specified format.

[0145] At step 808, the user interface may receive a revision request (e.g., similar to 132a-b in FIG. 2B) to the one or more structured objects (e.g., similar to 140a-n in FIG. 2B). In some implementations, the one or more structured objects are directly editable via a user input directly applied at the second user interface section to interact with the one or more structured objects, or a conversation input describing the revision request.

[0146] At step 810, the neural network based language model may generate an updated text response describing one or more revisions and one or more updated structured objects corresponding to the one or more revisions.

[0147] At step 812, the AI agent may cause the display, within the interactive user interface, of the updated text response at the first user interface section and the one or more updated structured objects at the second user interface section. For example, the one or more structured scripts (e.g., similar to structured data for artifacts 140a-n in FIG. 2A) corresponding to the one or more types of formats are rendered as a single output (e.g., similar to 310 in FIGS. 3A-3B) within the second user interface section.

[0148] The one or more structured objects are exportable to a local application on the user device without disrupting the one or more types of formats. The one or more structured objects may be created within a first conversation session at a memory (e.g., similar to artifact repository 219 in FIG. 2B) and then retrieved from the memory in response to a second task request for generating a new structured object in a second conversation session.

[0149] In some embodiments, method 800 is applicable in a variety of applications. For example, the task request received by a neural network model (e.g., LLM 120) may relate to a diagnostic request in view of a medical record in a healthcare system, a curriculum designing request in an online education system, a code generation request in a software development system, a writing and / or editing request in a content generation system, an IT diagnostic request in an IT customer service support system, a navigation request in a robotic and autonomous system, and / or the like. By performing method 800, the neural network based artificial agent may improve technology in the respective technical field in healthcare and diagnostics, education and personalized learning, software development and code assistance, content creation, autonomous system (such as autonomous driving, etc.), and / or the like.

[0150] For example, when the task query includes a query to write a code segment for identifying an information technology (IT) anomaly relating to a usage of an IT component such as a network gateway, a router, an online printer, and / or the like, by performing method 800 at an environment of a local area network (LAN), the neural network based artificial agent may receive an observation from the environment at which the next-step action is executed, and determine that the observation representing an information technology anomaly (e.g., a router failure, an unauthorized access attempt, a domain name system anomaly, and / or the like). In some implementations, the neural network based artificial agent may cause an alert relating to the information technology anomaly to be displayed at a visualized user interface. In this way, IT anomalies may be detected and alerted using the neural network based artificial agent in an efficient manner so as to improve network support technology.

[0151] This description and the accompanying drawings that illustrate inventive aspects, embodiments, implementations, or applications should not be taken as limiting. Various mechanical, compositional, structural, electrical, and operational changes may be made without departing from the spirit and scope of this description and the claims. In some instances, well-known circuits, structures, or techniques have not been shown or described in detail in order not to obscure the embodiments of this disclosure. Like numbers in two or more figures represent the same or similar elements.

[0152] In this description, specific details are set forth, describing some embodiments consistent with the present disclosure. Numerous specific details are set forth in order to provide a thorough understanding of the embodiments. It will be apparent, however, to one skilled in the art that some embodiments may be practiced without some or all of these specific details. The specific embodiments disclosed herein are meant to be illustrative but not limiting. One skilled in the art may realize other elements that, although not specifically described here, are within the scope and the spirit of this disclosure. In addition, to avoid unnecessary repetition, one or more features shown and described in association with one embodiment may be incorporated into other embodiments unless specifically described otherwise or if the one or more features would make an embodiment non-functional.

[0153] Although illustrative embodiments have been shown and described, a wide range of modification, change and substitution is contemplated in the foregoing disclosure and in some instances, some features of the embodiments may be employed without a corresponding use of other features. One of ordinary skill in the art would recognize many variations, alternatives, and modifications. Thus, the scope of the disclosed embodiments should be limited only by the following claims, and it is appropriate that the claims be construed broadly and, in a manner, consistent with the scope of the embodiments disclosed herein.

Claims

1. A method of operating an AI agent for creating a structured object in response to a task request, the method comprising:receiving, via an interactive user interface on a user device, a first task request relating to generating one or more structured objects;generating, by a neural network based language model at a server, an output comprising a first portion corresponding to a text response and a second portion corresponding to the one or more structured objects of one or more types of formats in response to the first task request;converting, by one or more application programming interfaces (APIs) at the server, the second portion into one or more structured scripts for object rendering according to the one or more types of formats;transmitting the text response and the one or more structured scripts to the user device that causes a display within the interactive user interface of the text response at a first user interface section and the one or more structured objects at a second user interface section independent of the first user interface section;receiving, via the interactive user interface, a revision request to the one or more structured objects;generating, by the neural network based language model, an updated text response describing one or more revisions and one or more updated structured objects corresponding to the one or more revisions; andtransmitting the updated text response and the one or more updated structured objects to the user device that causes the display within the interactive user interface of the updated text response at the first user interface section and the one or more updated structured objects at the second user interface section.

2. The method of claim 1, wherein the one or more structured objects comprise one or more of:a text document;a code snippet;a web page;an image;a diagram;a flow chart; andan interactive React component.

3. The method of claim 1, wherein the second portion comprises one or more function calls to invoke the one or more APIs to format model-generated content into the one or more structured objects of the one or more types of formats.

4. The method of claim 1, wherein the revision request is received via:a user input directly applied at the second user interface section to interact with the one or more structured objects; ora conversation input describing the revision request.

5. The method of claim 1, wherein the first user interface section comprises a dialog format within the interactive user interface, and the second user interface section comprises a foldable panel displayed on a side of the interactive user interface.

6. The method of claim 1, wherein the one or more structured objects are exportable to a local application on the user device without disrupting the one or more types of formats.

7. The method of claim 1, further comprising:storing the one or more structured objects created within a first conversation session at a memory of the server; andretrieving at least one of the one or more structured objects from the memory in response to a second task request for generating a new structured object in a second conversation session.

8. The method of claim 1, further comprising:determining the one or more APIs for creating the one or more structured objects based on the first task request;generating, by the neural network based language model, one or more function calls to the one or more APIs; andobtaining, through the one or more APIs, the one or more structured scripts corresponding to the one or more types of formats created by one or more applications hosted at the server.

9. The method of claim 8, wherein the one or more structured scripts corresponding to the one or more types of formats are rendered as a single output within the second user interface section.

10. A system of an AI agent for creating a structured object in response to a task request, the system comprising:a communication interface receiving, via an interactive user interface on a user device, a first task request relating to generating one or more structured objects;a memory storing a neural network based language model and a plurality of processor-executable instructions; andone or more processors to execute the plurality of processor-executable instructions to perform operations comprising:generating, by the neural network based language model, an output comprising a first portion corresponding to a text response and a second portion corresponding to the one or more structured objects of one or more types of formats in response to the first task request; andconverting, by one or more application programming interfaces (APIs), the second portion into one or more structured scripts for object rendering according to the one or more types of formats; andwherein the communication interface transmits the text response and the one or more structured scripts to the user device that causes a display, within the interactive user interface, of the text response at a first user interface section and the one or more structured objects at a second user interface section independent of the first user interface section;wherein the operations further comprise:receiving, via the interactive user interface, a revision request to the one or more structured objects;generating, by the neural network based language model, an updated text response describing one or more revisions and one or more updated structured objects corresponding to the one or more revisions; andwherein the communication interface further transmits the updated text response and the one or more updated structured objects to the user device that causes the display, within the interactive user interface, of the updated text response at the first user interface section and the one or more updated structured objects at the second user interface section.

11. The system of claim 10, wherein the one or more structured objects comprise one or more of:a text document;a code snippet;a web page;an image;a diagram;a flow chart; andan interactive React component.

12. The system of claim 10, wherein the second portion comprises one or more function calls to invoke the one or more APIs to format model-generated content into the one or more structured objects of the one or more types of formats.

13. The system of claim 10, wherein the revision request is received via:a user input directly applied at the second user interface section to interact with the one or more structured objects; ora conversation input describing the revision request.

14. The system of claim 10, wherein the first user interface section comprises a dialog format within the interactive user interface, and the second user interface section comprises a foldable panel displayed on a side of the interactive user interface.

15. The system of claim 10, wherein the one or more structured objects are exportable to a local application on the user device without disrupting the one or more types of formats.

16. The system of claim 10, wherein the operations further comprise:storing the one or more structured objects created within a first conversation session at the memory; andretrieving at least one of the one or more structured objects from the memory in response to a second task request for generating a new structured object in a second conversation session.

17. The system of claim 10, wherein the operations further comprise:determining the one or more APIs for creating the one or more structured objects based on the first task request;generating, by the neural network based language model, one or more function calls to the one or more APIs; andobtaining, through the one or more APIs, the one or more structured scripts corresponding to the one or more types of formats created by one or more applications hosted at the system.

18. A non-transitory machine-readable medium comprising a plurality of machine-executable instructions for operating an AI agent for creating a structured object in response to a task request, which, when executed by one or more processors, are adapted to cause the one or more processors to perform operations comprising:receiving, via an interactive user interface on a user device, a first task request relating to generating one or more structured objects; generating, by a neural network based language model at a server, an output comprising a first portion corresponding to a text response and a second portion corresponding to the one or more structured objects of one or more types of formats in response to the first task request;converting, by one or more application programming interfaces (APIs) at the server, the second portion into one or more structured scripts for object rendering according to the one or more types of formats;transmitting the text response and the one or more structured scripts to the user device that causes a display, within the interactive user interface, of the text response at a first user interface section and the one or more structured objects at a second user interface section independent of the first user interface section;receiving, via the interactive user interface, a revision request to the one or more structured objects;generating, by the neural network based language model, an updated text response describing one or more revisions and one or more updated structured objects corresponding to the one or more revisions; andtransmitting the updated text response and the one or more updated structured objects to the user device that causes the display within the interactive user interface of the updated text response at the first user interface section and the one or more updated structured objects at the second user interface section.

Citation Information

Patent Citations

  • User Authentication with Voiceprints on Online Social Networks

    US20190182176A1