Action Items

Finds spans in the text with Action Items.

Alex:
How many participants and what time are you looking at? ACTION_ITEM Let me know if you'd prefer to hop on a quick videochat tomorrow to go over all the logistics.

Justin:
Hi Alex! ACTION-ITEM There are 12 of us, and I believe 8 will take part.

Alex:
ACTION-ITEM I'll send over a call invite with a zoom link and look forward to chatting then!

Justin:
Thank you!

📘

Use Action-Items Skill to extract:

👍

Benchmarks

Coming soon...

Output labels

Type

Value

action-item

The extracted action item

Parameters

None.

Example

Request

curl -X POST \
'https://api.oneai.com/api/v0/pipeline' \
-H 'accept: application/json' \
-H 'Content-Type: application/json' \
-H 'api-key: <YOUR-API-KEY-HERE>' \
-d '{
    "input": [{ "speaker": "John", "utterance": "Yeah, I think so. So any d o t? What was that? Sorry? I cut out a little bit. Yeah, sure. Anna, Diane? Oh, God. Yeah, correct. Okay. Do you guys have a white paper or something I can take a look at on the website somewhere.", "timestamp": "0:00" }, { "speaker": "speaker 2", "utterance": "..." }],
    "input_type": "conversation",
        "content_type": "application/json",
    "steps": [
      {
        "skill": "action-items"
      }   
    ]
}'
const OneAI = require("oneai");
const oneai = new OneAI("<YOUR-API-KEY-HERE>");
const conversation = new oneai.Conversation(
  [{ "speaker": "John", "utterance": "Yeah, I think so. So any d o t? What was that? Sorry? I cut out a little bit. Yeah, sure. Anna, Diane? Oh, God. Yeah, correct. Okay. Do you guys have a white paper or something I can take a look at on the website somewhere.", "timestamp": "0:00" }, { "speaker": "speaker 2", "utterance": "..." }]
);

const pipeline = new oneai.Pipeline(
    oneai.skills.actionItems(),
);

const output = await pipeline.run(conversation);
import oneai

oneai.api_key = "<YOUR-API-KEY-HERE>"
pipeline = oneai.Pipeline(
  steps = [
        oneai.skills.ActionItems(),
  ]
)

conversation = oneai.Conversation(
  [{ "speaker": "John", "utterance": "Yeah, I think so. So any d o t? What was that? Sorry? I cut out a little bit. Yeah, sure. Anna, Diane? Oh, God. Yeah, correct. Okay. Do you guys have a white paper or something I can take a look at on the website somewhere.", "timestamp": "0:00" }, { "speaker": "speaker 2", "utterance": "..." }]
)

output = pipeline.run(conversation)

Response

{
   "input_text":"[0:00] John:\nYeah, I think so. So any d o t? What was that? Sorry? I cut out a little bit. Yeah, sure. Anna, Diane? Oh, God. Yeah, correct. Okay. Do you guys have a white paper or something I can take a look at on the website somewhere.\n\nspeaker 2:\n...\n\n",
   "status":"success",
   "output":[
      {
         "text_generated_by_step_name":"input",
         "text_generated_by_step_id":0,
         "text":"[0:00] John:\nYeah, I think so. So any d o t? What was that? Sorry? I cut out a little bit. Yeah, sure. Anna, Diane? Oh, God. Yeah, correct. Okay. Do you guys have a white paper or something I can take a look at on the website somewhere.\n\nspeaker 2:\n...\n\n",
         "labels":[
            {
               "type":"action-item",
               "skill":"action-items",
               "name":"Action item",
               "value":"Do you guys have a white paper or something I can take a look at on the website somewhere.",
               "speaker":"John",
               "span_text":"Do you guys have a white paper or something I can take a look at on the website somewhere.",
               "span":[
                  146,
                  236
               ],
               "output_spans":[
                  {
                     "section":0,
                     "start":133,
                     "end":223
                  }
               ]
            }
         ]
      }
   ],
   "stats":{
      "concurrency_wait_time":0.0,
      "total_running_jobs":1,
      "total_waiting_jobs":0
   }
}
{
  text: '[0:00] John:\n' +
    'Yeah, I think so. So any d o t? What was that? Sorry? I cut out a little bit. Yeah, sure. Anna, Diane? Oh, God. Yeah, correct. Okay. Do you guys have a white paper or something I can take a look at on the website somewhere.\n' +
    '\n' +
    'speaker 2:\n' +
    '...\n' +
    '\n',
  actionItems: [
    {
      type: 'action-item',
      skill: 'action-items',
      name: 'Action item',
      value: 'Do you guys have a white paper or something I can take a look at on the website somewhere.',
      speaker: 'John',
      span_text: 'Do you guys have a white paper or something I can take a look at on the website somewhere.',
      span: [ 146, 236 ],
      output_spans: [ { section: 0, start: 133, end: 223 } ]
    }
  ]
}

Did this page help you?