@okcashpro/okai v0.1.7-alpha.1 / IAgentRuntime
Interface: IAgentRuntime
Properties
agentId
agentId: `${string}-${string}-${string}-${string}-${string}`
Properties
Defined in
packages/core/src/types.ts:1026
serverUrl
serverUrl:
string
Defined in
packages/core/src/types.ts:1027
databaseAdapter
databaseAdapter:
IDatabaseAdapter
Defined in
packages/core/src/types.ts:1028
token
token:
string
Defined in
packages/core/src/types.ts:1029
modelProvider
modelProvider:
ModelProviderName
Defined in
packages/core/src/types.ts:1030
imageModelProvider
imageModelProvider:
ModelProviderName
Defined in
packages/core/src/types.ts:1031
character
character:
Character
Defined in
packages/core/src/types.ts:1032
providers
providers:
Provider
[]
Defined in
packages/core/src/types.ts:1033
actions
actions:
Action
[]
Defined in
packages/core/src/types.ts:1034
evaluators
evaluators:
Evaluator
[]
Defined in
packages/core/src/types.ts:1035
plugins
plugins:
Plugin
[]
Defined in
packages/core/src/types.ts:1036
fetch()?
optional
fetch: (input
,init
?) =>Promise
<Response
>(input
,init
?) =>Promise
<Response
>
Parameters
• input: RequestInfo
| URL
• init?: RequestInit
Returns
Promise
<Response
>
Parameters
• input: string
| Request
| URL
• init?: RequestInit
Returns
Promise
<Response
>
Defined in
packages/core/src/types.ts:1038
messageManager
messageManager:
IMemoryManager
Defined in
packages/core/src/types.ts:1040
descriptionManager
descriptionManager:
IMemoryManager
Defined in
packages/core/src/types.ts:1041
documentsManager
documentsManager:
IMemoryManager
Defined in
packages/core/src/types.ts:1042
knowledgeManager
knowledgeManager:
IMemoryManager
Defined in
packages/core/src/types.ts:1043
loreManager
loreManager:
IMemoryManager
Defined in
packages/core/src/types.ts:1044
cacheManager
cacheManager:
ICacheManager
Defined in
packages/core/src/types.ts:1046
services
services:
Map
<ServiceType
,Service
>
Defined in
packages/core/src/types.ts:1048
clients
clients:
Record
<string
,any
>
any could be EventEmitter but I think the real solution is forthcoming as a base client interface
Defined in
packages/core/src/types.ts:1051
Methods
initialize()
initialize():
Promise
<void
>
Returns
Promise
<void
>
Defined in
packages/core/src/types.ts:1053
registerMemoryManager()
registerMemoryManager(
manager
):void
Parameters
• manager: IMemoryManager
Returns
void
Defined in
packages/core/src/types.ts:1055
getMemoryManager()
getMemoryManager(
name
):IMemoryManager
Parameters
• name: string
Returns
Defined in
packages/core/src/types.ts:1057
getService()
getService<
T
>(service
):T
Type Parameters
• T extends Service
Parameters
• service: ServiceType
Returns
T
Defined in
packages/core/src/types.ts:1059
registerService()
registerService(
service
):void
Parameters
• service: Service
Returns
void
Defined in
packages/core/src/types.ts:1061
getSetting()
getSetting(
key
):string
Parameters
• key: string
Returns
string
Defined in
packages/core/src/types.ts:1063
getConversationLength()
getConversationLength():
number
Methods
Returns
number
Defined in
packages/core/src/types.ts:1066
processActions()
processActions(
message
,responses
,state
?,callback
?):Promise
<void
>
Parameters
• message: Memory
• responses: Memory
[]
• state?: State
• callback?: HandlerCallback
Returns
Promise
<void
>
Defined in
packages/core/src/types.ts:1068
evaluate()
evaluate(
message
,state
?,didRespond
?,callback
?):Promise
<string
[]>
Parameters
• message: Memory
• state?: State
• didRespond?: boolean
• callback?: HandlerCallback
Returns
Promise
<string
[]>
Defined in
packages/core/src/types.ts:1075
ensureParticipantExists()
ensureParticipantExists(
userId
,roomId
):Promise
<void
>
Parameters
• userId: `${string}-${string}-${string}-${string}-${string}`
• roomId: `${string}-${string}-${string}-${string}-${string}`
Returns
Promise
<void
>
Defined in
packages/core/src/types.ts:1082
ensureUserExists()
ensureUserExists(
userId
,userName
,name
,source
):Promise
<void
>
Parameters
• userId: `${string}-${string}-${string}-${string}-${string}`
• userName: string
• name: string
• source: string
Returns
Promise
<void
>
Defined in
packages/core/src/types.ts:1084
registerAction()
registerAction(
action
):void
Parameters
• action: Action
Returns
void
Defined in
packages/core/src/types.ts:1091
ensureConnection()
ensureConnection(
userId
,roomId
,userName
?,userScreenName
?,source
?):Promise
<void
>
Parameters
• userId: `${string}-${string}-${string}-${string}-${string}`
• roomId: `${string}-${string}-${string}-${string}-${string}`
• userName?: string
• userScreenName?: string
• source?: string
Returns
Promise
<void
>
Defined in
packages/core/src/types.ts:1093
ensureParticipantInRoom()
ensureParticipantInRoom(
userId
,roomId
):Promise
<void
>
Parameters
• userId: `${string}-${string}-${string}-${string}-${string}`
• roomId: `${string}-${string}-${string}-${string}-${string}`
Returns
Promise
<void
>
Defined in
packages/core/src/types.ts:1101
ensureRoomExists()
ensureRoomExists(
roomId
):Promise
<void
>
Parameters
• roomId: `${string}-${string}-${string}-${string}-${string}`
Returns
Promise
<void
>
Defined in
packages/core/src/types.ts:1103
composeState()
composeState(
message
,additionalKeys
?):Promise
<State
>
Parameters
• message: Memory
• additionalKeys?
Returns
Promise
<State
>
Defined in
packages/core/src/types.ts:1105
updateRecentMessageState()
updateRecentMessageState(
state
):Promise
<State
>
Parameters
• state: State
Returns
Promise
<State
>