com.alecdorrington.iris
Members list
Packages
Type members
Classlikes
Attributes
- Companion
- class
- Supertypes
-
trait Producttrait Mirrorclass Objecttrait Matchableclass Any
- Self type
-
Conversation.type
The full history of a conversation with a model, sent whole with every request. To go on with a conversation, append the model's response and the user's next message, then send the conversation again:
The full history of a conversation with a model, sent whole with every request. To go on with a conversation, append the model's response and the user's next message, then send the conversation again:
for
first <- query.send[String](conversation)
asked <- first.attempts
next = conversation.modelSays(asked.last).userSays("Tell me more.")
second <- query.send[String](next)
yield second.value
Asked of a conversation ending with the model's message, the model is told what to answer in a message of the user's after it, and so answers afresh rather than going on with its own response. A conversation with no messages, a message of breakpoints alone, or no message of the user's fails with PromptError.Unsendable before any request is made.
Value parameters
- instructions
-
The instructions, if any, setting the model's general behaviour, sent as the provider's system message.
- messages
-
The messages exchanged so far, oldest first.
Attributes
- Companion
- object
- Supertypes
-
trait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass AnyShow all
The kind of a picture, document or other media in a MessagePart.Media, by its IANA media type. The kinds Iris lists are constants (MediaType.Png), so that a provider refuses one it cannot take before any request is spent finding out; any other is an MediaType.Other, sent only to Gemini, which takes audio and video as well, and judges for itself.
The kind of a picture, document or other media in a MessagePart.Media, by its IANA media type. The kinds Iris lists are constants (MediaType.Png), so that a provider refuses one it cannot take before any request is spent finding out; any other is an MediaType.Other, sent only to Gemini, which takes audio and video as well, and judges for itself.
Attributes
- Companion
- object
- Supertypes
-
class Objecttrait Matchableclass Any
- Known subtypes
A single message in a Conversation, one case for each of its owners, holding only the parts that owner writes.
A single message in a Conversation, one case for each of its owners, holding only the parts that owner writes.
Attributes
- Companion
- object
- Supertypes
-
trait Enumtrait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass AnyShow all
Attributes
- Companion
- trait
- Supertypes
-
trait Sumtrait Mirrorclass Objecttrait Matchableclass Any
- Self type
-
MessagePart.type
A part of a message. A message is a list of parts, so that text and media travel together in reading order. Each owner of a message writes parts of its own kinds: UserParts, ModelParts and ToolParts.
A part of a message. A message is a list of parts, so that text and media travel together in reading order. Each owner of a message writes parts of its own kinds: UserParts, ModelParts and ToolParts.
Attributes
- Companion
- object
- Supertypes
-
class Objecttrait Matchableclass Any
- Known subtypes
-
trait ModelPartobject CacheBreakpointclass Textclass ToolCalltrait ToolPartclass ToolResulttrait UserPartclass MediaShow all
A part of a message of the model's: text, a tool call or a breakpoint.
A part of a message of the model's: text, a tool call or a breakpoint.
Attributes
- Companion
- object
- Supertypes
- Known subtypes
What a model's tokens cost, in Usd per million tokens, with one rate for each of Usage's counts, as its provider charges on its standard tier. A count the provider charges nothing apart for is charged as the rest of its kind: cache writes as input where writing the cache costs nothing more, audio as other input where it is priced alike, and thinking as the reply.
What a model's tokens cost, in Usd per million tokens, with one rate for each of Usage's counts, as its provider charges on its standard tier. A count the provider charges nothing apart for is charged as the rest of its kind: cache writes as input where writing the cache costs nothing more, audio as other input where it is priced alike, and thinking as the reply.
Value parameters
- above
-
The rates instead of these for a request whose prompt is longer, where the provider charges more for a long prompt.
- cacheRead
-
The rate of tokens of the request read from the cache, other than audio.
- cacheReadAudio
-
The rate of tokens of audio read from the cache.
- cacheWrite
-
The rate of tokens of the request written to the cache.
- thinking
-
The rate of tokens the model thought in.
- uncached
-
The rate of tokens of the request read afresh, other than audio.
- uncachedAudio
-
The rate of tokens of audio read afresh.
- visible
-
The rate of tokens the model replied with.
Attributes
- Companion
- object
- Supertypes
-
trait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass AnyShow all
A part of a message of the tools': a tool's result or a breakpoint.
A part of a message of the tools': a tool's result or a breakpoint.
Attributes
- Supertypes
- Known subtypes
-
object CacheBreakpointclass ToolResult
The token counts of one request or more, as the provider reported them, alike for every provider. No count includes another, so that each may be priced alone. A count the provider did not report is 0, as is one it never charges for apart: Gemini charges nothing for writing its cache, nor OpenAI before GPT-5.6, and only Gemini reports audio apart.
The token counts of one request or more, as the provider reported them, alike for every provider. No count includes another, so that each may be priced alone. A count the provider did not report is 0, as is one it never charges for apart: Gemini charges nothing for writing its cache, nor OpenAI before GPT-5.6, and only Gemini reports audio apart.
Value parameters
- cacheReadAudioTokens
-
The number of tokens of audio in the request read from the provider's cache.
- cacheReadTokens
-
The number of tokens of the request read from the provider's cache, other than audio.
- cacheWriteTokens
-
The number of tokens of the request written to the provider's cache, where the provider charges for writing them.
- thinkingTokens
-
The number of tokens the model thought in before it replied, whether or not the provider shows what it thought.
- uncachedAudioTokens
-
The number of tokens of audio in the request read afresh.
- uncachedTokens
-
The number of tokens of the request read afresh, other than audio.
- visibleTokens
-
The number of tokens the model replied with: its text and tool calls.
Attributes
- Supertypes
-
trait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass AnyShow all
An amount of US dollars, the currency every provider prices in. Iris converts it to no other: a host billed in another currency converts it at its own rate, which the one billing it sets. Nor does it count tax, credits or a discount of one's own.
An amount of US dollars, the currency every provider prices in. Iris converts it to no other: a host billed in another currency converts it at its own rate, which the one billing it sets. Nor does it count tax, credits or a discount of one's own.
Value parameters
- amount
-
The number of dollars.
Attributes
- Companion
- object
- Supertypes
-
trait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass AnyShow all
A part of a message of the user's: text, media or a cache breakpoint.
A part of a message of the user's: text, media or a cache breakpoint.
Attributes
- Companion
- object
- Supertypes
- Known subtypes