For the complete documentation index, see llms.txt. This page is also available as Markdown.

Tasks

Run and manage tasks with the Edison client.

Overview

Edison client implements a RestClient (called EdisonClient) with the following functionalities:

  • Simple task running: run_tasks_until_done(TaskRequest) or await arun_tasks_until_done(TaskRequest)

  • Asynchronous tasks: get_task(task_id) or aget_task(task_id) and create_task(TaskRequest) or acreate_task(TaskRequest)

To create a EdisonClient, you need to pass an Edison Scientific platform api key (see Authentication):

Task types

In the Edison platform, we define the deployed combination of an agent and an environment as a job.

To invoke a job, we need to submit a task (also called a query) to it. EdisonClient can be used to submit tasks/queries to available jobs in the Edison platform.

Using an EdisonClient instance, you can submit tasks to the platform by calling the create_task method, which receives a TaskRequest (or a dictionary with kwargs) and returns the task ID.

Aiming to make the submission of tasks as simple as possible, we have created a JobNames enum that contains the available task types.

Please note that Kosmos is not available via API.

Alias
Task type
Description

JobNames.LITERATURE

Literature search

Ask a question of scientific data sources, and receive a high-accuracy, cited response. Built with PaperQA3.

JobNames.LITERATURE_HIGH

Literature search

Ask a question of scientific data sources, and receive a high-accuracy, cited response. High reasoning mode enabled for SOTA performance.

JobNames.ANALYSIS

Data analysis

Turn biological datasets into detailed analyses answering your research questions.

JobNames.PRECEDENT

Precedent search

Formerly known as HasAnyone, query if anyone has ever done something in science.

JobNames.MOLECULES

Chemistry tasks

A new iteration of ChemCrow, Phoenix uses cheminformatics tools to do chemistry. Good for planning synthesis and designing new molecules.

Submitting tasks

Using JobNames, the task submission looks like this:

Asynchronous tasks

Sometimes you may want to submit many jobs, while querying results at a later time. The platform API supports this, as shown below.

Batch task submission

In either the sync or the async code, collections of tasks can be given to the client to run them in a batch:

Task continuation

Once a task is submitted and the answer is returned, Edison platform allow you to ask follow-up questions to the previous task. It is also possible through the platform API. To accomplish that, we can use the runtime_config we discussed in the Simple task running section.

Last updated