שתף באמצעות


Cohere (Independent Publisher) (Preview)

Cohere is making natural language processing part of every developer's toolkit. Harness the power of language understanding. Join the developers and businesses who are using Cohere to generate, categorize and organize text at a scale that was previously unimaginable.

This connector is available in the following products and regions:

Service Class Regions
Logic Apps Standard All Logic Apps regions except the following:
     -   Azure Government regions
     -   Azure China regions
     -   US Department of Defense (DoD)
Power Automate Premium All Power Automate regions except the following:
     -   US Government (GCC)
     -   US Government (GCC High)
     -   China Cloud operated by 21Vianet
     -   US Department of Defense (DoD)
Power Apps Premium All Power Apps regions except the following:
     -   US Government (GCC)
     -   US Government (GCC High)
     -   China Cloud operated by 21Vianet
     -   US Department of Defense (DoD)
Contact
Name Troy Taylor
URL https://www.hitachisolutions.com
Email ttaylor@hitachisolutions.com
Connector Metadata
Publisher Troy Taylor
Website https://cohere.ai/
Privacy policy https://cohere.ai/privacy
Categories AI

Creating a connection

The connector supports the following authentication types:

Default Parameters for creating connection. All regions Not shareable

Default

Applicable: All regions

Parameters for creating connection.

This is not shareable connection. If the power app is shared with another user, another user will be prompted to create new connection explicitly.

Name Type Description Required
API Key in the form 'Bearer API_Key' securestring The API Key in the form 'Bearer API_Key' for this api True

Throttling Limits

Name Calls Renewal Period
API calls per connection 100 60 seconds

Actions

Generate classification

Creates a prediction about which label fits the specified text inputs best.

Generate detokenized text

Converts tokens using byte-pair encoding and returns their text representation.

Generate text [DEPRECATED]

This action generates realistic text conditioned on a given input.

Generate text embeddings

Returns text embeddings which are lists of floating point numbers that captures semantic information about the text that it represents.

Generate tokens

Splits input text into smaller units called tokens using byte-pair encoding (BPE).

Get chat

Generates a text response to a user message.

Identify language

Detects which language each of the provided texts is written in.

Summarize text [DEPRECATED]

Generates a summary in English for a given text.

Generate classification

Creates a prediction about which label fits the specified text inputs best.

Parameters

Name Key Required Type Description
Inputs
inputs array of string

The inputs.

Model
model string

The model.

Text
text string

The text.

Label
label string

The label.

Preset
preset string

The preset.

Truncate
truncate string

The truncate.

Returns

Name Path Type Description
ID
id string

The identifier.

Classifications
classifications array of object
ID
classifications.id string

The identifier.

Input
classifications.input string

The input.

Prediction
classifications.prediction string

The prediction.

Confidence
classifications.confidence float

The confidence.

Confidences
classifications.confidences array of object
Option
classifications.confidences.option string

The option.

Confidence
classifications.confidences.confidence float

The confidence.

Confidence
classifications.labels.Not spam.confidence float

The confidence.

Confidence
classifications.labels.Spam.confidence float

The confidence.

Version
meta.api_version.version string

The version.

Is Deprecated
meta.api_version.is_deprecated boolean

Whether is deprecated.

Generate detokenized text

Converts tokens using byte-pair encoding and returns their text representation.

Parameters

Name Key Required Type Description
Tokens
tokens array of integer

The tokens.

Returns

Name Path Type Description
Text
text string

The text.

Version
meta.api_version.version string

The version.

Is Deprecated
meta.api_version.is_deprecated boolean

Whether is deprecated.

Generate text [DEPRECATED]

This action generates realistic text conditioned on a given input.

Parameters

Name Key Required Type Description
Prompt
prompt string

The prompt.

Model
model string

The model.

Num Generations
num_generations integer

The number of generations.

Max Tokens
max_tokens integer

The maximum number of tokens.

Preset
preset string

The preset.

Temperature
temperature float

The temperature.

k
k integer

The k value.

p
p float

The p value.

Frequency Penalty
frequency_penalty float

The frequency penalty.

Presence Penalty
presence_penalty float

The presence penalty.

End Sequences
end_sequences array of string

The end sequences.

Stop Sequences
stop_sequences array of string

The stop sequences.

Return Likelihoods
return_likelihoods string

The return likelihoods.

Truncate
truncate string

The truncate.

Returns

Name Path Type Description
ID
id string

The identifier.

Generations
generations array of object
ID
generations.id string

The identifier.

Text
generations.text string

The text.

Prompt
prompt string

The prompt.

Generate text embeddings

Returns text embeddings which are lists of floating point numbers that captures semantic information about the text that it represents.

Parameters

Name Key Required Type Description
Texts
texts array of string

The texts.

Model
model string

The model.

Truncate
truncate string

The truncate.

Returns

Name Path Type Description
ID
id string

The identifier.

Texts
texts array of string

The texts.

Embeddings
embeddings array of array

The embeddings.

items
embeddings array of float
Version
meta.api_version.version string

The version.

Is Deprecated
meta.api_version.is_deprecated boolean

Whether is deprecated.

Generate tokens

Splits input text into smaller units called tokens using byte-pair encoding (BPE).

Parameters

Name Key Required Type Description
Text
text string

The text.

Returns

Name Path Type Description
Tokens
tokens array of integer

The tokens.

Token Strings
token_strings array of string

The token strings.

Version
meta.api_version.version string

The version.

Is Deprecated
meta.api_version.is_deprecated boolean

Whether is deprecated.

Get chat

Generates a text response to a user message.

Parameters

Name Key Required Type Description
Message
message True string

Text input for the model to respond to.

Model
model string

The name of a compatible Cohere model or the ID of a fine-tuned model.

Preamble
preamble string

When specified, the default Cohere preamble will be replaced with the provided one. Preambles are a part of the prompt used to adjust the model's overall behavior and conversation style, and use the SYSTEM role.

Role
role string

The role.

Message
message string

The previous message.

Conversation ID
conversation_id string

An alternative to chat history. Providing a conversation_id creates or resumes a persisted conversation with the specified ID. The ID can be any non empty string.

Prompt Truncation
prompt_truncation string

Dictates how the prompt will be constructed.

ID
id string

The identifier of the connector.

User Access Token
user_access_token string

When specified, this user access token will be passed to the connector in the Authorization header instead of the Cohere generated one.

Continue On Failure
continue_on_failure boolean

When true, the request will continue if this connector returned an error.

Search Queries Only
search_queries_only boolean

When true, the response will only contain a list of generated search queries, but no search will take place, and no reply from the model to the user's message will be generated.

Title
title string

The document title.

Text
text string

The document text.

Citation Quality
citation_quality string

Dictates the approach taken to generating citations as part of the RAG flow by allowing the user to specify whether they want accurate results or fast results.

Temperature
temperature float

A non-negative float that tunes the degree of randomness in generation. Lower temperatures mean less random generations, and higher temperatures mean more random generations.

Max Tokens
max_tokens integer

The maximum number of tokens the model will generate as part of the response. Note: Setting a low value may result in incomplete generations.

Max Input Tokens
max_input_tokens integer

The maximum number of input tokens to send to the model. If not specified, max_input_tokens is the model's context length limit minus a small buffer.

k
k integer

Ensures only the top k most likely tokens are considered for generation at each step. Defaults to 0, min value of 0, max value of 500.

p
p float

Ensures that only the most likely tokens, with total probability mass of p, are considered for generation at each step. If both k and p are enabled, p acts after k. Defaults to 0.75. min value of 0.01, max value of 0.99.

Seed
seed float

If specified, the backend will make a best effort to sample tokens deterministically, such that repeated requests with the same seed and parameters should return the same result. However, determinism cannot be totally guaranteed.

Stop Sequences
stop_sequences array of string

A list of up to 5 strings that the model will use to stop generation. If the model generates a string that matches any of the strings in the list, it will stop generating tokens and return the generated text up to that point not including the stop sequence.

Frequency Penalty
frequency_penalty float

Used to reduce repetitiveness of generated tokens. The higher the value, the stronger a penalty is applied to previously present tokens, proportional to how many times they have already appeared in the prompt or prior generation.

Presence Penalty
presence_penalty float

Used to reduce repetitiveness of generated tokens. Similar to frequency_penalty, except that this penalty is applied equally to all tokens that have already appeared, regardless of their exact frequencies.

Name
name string

The name of the tool to be called. Valid names contain only the characters a-z, A-Z, 0-9, _ and must not begin with a digit.

Description
description string

The description of what the tool does, the model uses the description to choose when and how to call the function.

Returns

Name Path Type Description
Text
text string

The text.

Generation ID
generation_id string

The generation identifier.

Citations
citations array of object
Start
citations.start integer

The start.

End
citations.end integer

The end.

Text
citations.text string

The text.

Document IDs
citations.document_ids array of string

The document identifiers.

Documents
documents array of object
ID
documents.id string

The identifier.

Additional Properties
documents.additionalProp string

The additional properties.

Is Search Required
is_search_required boolean

Whether is search required.

Search Queries
search_queries array of object
Text
search_queries.text string

The text.

Generation ID
search_queries.generation_id string

The generation identifier.

Search Results
search_results array of object
Text
search_results.search_query.text string

The text.

Generation ID
search_results.search_query.generation_id string

The generation identifier.

ID
search_results.connector.id string

The identifier.

Document IDs
search_results.document_ids array of string

The document identifiers.

Error Message
search_results.error_message string

The error message.

Continue On Failure
search_results.continue_on_failure boolean

Whether to continue on failure.

Finish Reason
finish_reason string

The finish reason.

Tool Calls
tool_calls array of object
Name
tool_calls.name string

The name.

Chat History
chat_history array of object
Role
chat_history.role string

The role.

Message
chat_history.message string

The message.

Version
meta.api_version.version string

The version.

Is Deprecated
meta.api_version.is_deprecated boolean

Whether is deprecated.

Is Experimental
meta.api_version.is_experimental boolean

Whether is experimental.

Input Tokens
meta.billed_units.input_tokens integer

The input tokens.

Output Tokens
meta.billed_units.output_tokens integer

The output tokens.

Search Units
meta.billed_units.search_units integer

The search units.

Classifications
meta.billed_units.classifications integer

The classifications.

Input Tokens
meta.tokens.input_tokens integer

The input tokens.

Output Tokens
meta.tokens.output_tokens integer

The output tokens.

Warnings
meta.warnings array of string

The warnings.

Identify language

Detects which language each of the provided texts is written in.

Parameters

Name Key Required Type Description
Texts
texts array of string

The texts.

Returns

Name Path Type Description
ID
id string

The identifier.

Results
results array of object
Language Code
results.language_code string

The language code.

Language Name
results.language_name string

The language name.

Version
meta.api_version.version string

The version.

Is Deprecated
meta.api_version.is_deprecated boolean

Whether is deprecated.

Summarize text [DEPRECATED]

Generates a summary in English for a given text.

Parameters

Name Key Required Type Description
Length
length string

The length.

Format
format string

The format.

Model
model string

The model.

Extractiveness
extractiveness string

The extractiveness.

Temperature
temperature float

The temperature.

Text
text string

The text.

Returns

Name Path Type Description
ID
id string

The identifier.

Summary
summary string

The summary.

Version
meta.api_version.version string

The version.

Is Deprecated
meta.api_version.is_deprecated boolean

Whether is deprecated.