intentkit 0.6.2.dev1__py3-none-any.whl → 0.6.3.dev1__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of intentkit might be problematic. Click here for more details.
- intentkit/__init__.py +1 -1
- intentkit/clients/twitter.py +58 -0
- intentkit/core/credit.py +20 -0
- intentkit/models/credit.py +9 -0
- intentkit/skills/acolyt/ask.py +1 -2
- intentkit/skills/cdp/__init__.py +11 -0
- intentkit/skills/cdp/schema.json +16 -0
- intentkit/skills/cdp/swap.py +121 -0
- intentkit/skills/system/read_agent_api_key.py +1 -1
- intentkit/skills/system/regenerate_agent_api_key.py +1 -1
- {intentkit-0.6.2.dev1.dist-info → intentkit-0.6.3.dev1.dist-info}/METADATA +15 -39
- {intentkit-0.6.2.dev1.dist-info → intentkit-0.6.3.dev1.dist-info}/RECORD +14 -13
- {intentkit-0.6.2.dev1.dist-info → intentkit-0.6.3.dev1.dist-info}/WHEEL +0 -0
- {intentkit-0.6.2.dev1.dist-info → intentkit-0.6.3.dev1.dist-info}/licenses/LICENSE +0 -0
intentkit/__init__.py
CHANGED
intentkit/clients/twitter.py
CHANGED
|
@@ -3,9 +3,12 @@ import os
|
|
|
3
3
|
import tempfile
|
|
4
4
|
from datetime import datetime, timedelta, timezone
|
|
5
5
|
from typing import Any, Dict, List, NotRequired, Optional, TypedDict
|
|
6
|
+
from urllib.parse import urlencode
|
|
6
7
|
|
|
7
8
|
import httpx
|
|
8
9
|
from pydantic import BaseModel, Field
|
|
10
|
+
from requests.auth import HTTPBasicAuth
|
|
11
|
+
from requests_oauthlib import OAuth2Session
|
|
9
12
|
from tweepy.asynchronous import AsyncClient
|
|
10
13
|
|
|
11
14
|
from intentkit.abstracts.skill import SkillStoreABC
|
|
@@ -443,3 +446,58 @@ async def unlink_twitter(agent_id: str) -> AgentData:
|
|
|
443
446
|
"twitter_refresh_token": None,
|
|
444
447
|
},
|
|
445
448
|
)
|
|
449
|
+
|
|
450
|
+
|
|
451
|
+
# this class is forked from:
|
|
452
|
+
# https://github.com/tweepy/tweepy/blob/main/tweepy/auth.py
|
|
453
|
+
# it is not maintained by the original author, bug need to be fixed
|
|
454
|
+
class OAuth2UserHandler(OAuth2Session):
|
|
455
|
+
"""OAuth 2.0 Authorization Code Flow with PKCE (User Context)
|
|
456
|
+
authentication handler
|
|
457
|
+
"""
|
|
458
|
+
|
|
459
|
+
def __init__(self, *, client_id, redirect_uri, scope, client_secret=None):
|
|
460
|
+
super().__init__(client_id, redirect_uri=redirect_uri, scope=scope)
|
|
461
|
+
if client_secret is not None:
|
|
462
|
+
self.auth = HTTPBasicAuth(client_id, client_secret)
|
|
463
|
+
else:
|
|
464
|
+
self.auth = None
|
|
465
|
+
self.code_challenge = self._client.create_code_challenge(
|
|
466
|
+
self._client.create_code_verifier(128), "S256"
|
|
467
|
+
)
|
|
468
|
+
|
|
469
|
+
def get_authorization_url(self, agent_id: str, redirect_uri: str):
|
|
470
|
+
"""Get the authorization URL to redirect the user to
|
|
471
|
+
|
|
472
|
+
Args:
|
|
473
|
+
agent_id: ID of the agent to authenticate
|
|
474
|
+
redirect_uri: URI to redirect to after authorization
|
|
475
|
+
"""
|
|
476
|
+
state_params = {"agent_id": agent_id, "redirect_uri": redirect_uri}
|
|
477
|
+
authorization_url, _ = self.authorization_url(
|
|
478
|
+
"https://x.com/i/oauth2/authorize",
|
|
479
|
+
state=urlencode(state_params),
|
|
480
|
+
code_challenge=self.code_challenge,
|
|
481
|
+
code_challenge_method="S256",
|
|
482
|
+
)
|
|
483
|
+
return authorization_url
|
|
484
|
+
|
|
485
|
+
def get_token(self, authorization_response):
|
|
486
|
+
"""After user has authorized the app, fetch access token with
|
|
487
|
+
authorization response URL
|
|
488
|
+
"""
|
|
489
|
+
return super().fetch_token(
|
|
490
|
+
"https://api.x.com/2/oauth2/token",
|
|
491
|
+
authorization_response=authorization_response,
|
|
492
|
+
auth=self.auth,
|
|
493
|
+
include_client_id=True,
|
|
494
|
+
code_verifier=self._client.code_verifier,
|
|
495
|
+
)
|
|
496
|
+
|
|
497
|
+
def refresh(self, refresh_token: str):
|
|
498
|
+
"""Refresh token"""
|
|
499
|
+
return super().refresh_token(
|
|
500
|
+
"https://api.x.com/2/oauth2/token",
|
|
501
|
+
refresh_token=refresh_token,
|
|
502
|
+
include_client_id=True,
|
|
503
|
+
)
|
intentkit/core/credit.py
CHANGED
|
@@ -10,6 +10,7 @@ from sqlalchemy import desc, select
|
|
|
10
10
|
from sqlalchemy.ext.asyncio import AsyncSession
|
|
11
11
|
|
|
12
12
|
from intentkit.models.agent import Agent
|
|
13
|
+
from intentkit.models.agent_data import AgentData
|
|
13
14
|
from intentkit.models.app_setting import AppSetting
|
|
14
15
|
from intentkit.models.credit import (
|
|
15
16
|
DEFAULT_PLATFORM_ACCOUNT_ADJUSTMENT,
|
|
@@ -150,6 +151,7 @@ async def recharge(
|
|
|
150
151
|
permanent_amount=amount, # Set permanent_amount since this is a permanent credit
|
|
151
152
|
free_amount=Decimal("0"), # No free credits involved
|
|
152
153
|
reward_amount=Decimal("0"), # No reward credits involved
|
|
154
|
+
agent_wallet_address=None, # No agent involved in recharge
|
|
153
155
|
note=note,
|
|
154
156
|
)
|
|
155
157
|
session.add(event)
|
|
@@ -258,6 +260,7 @@ async def reward(
|
|
|
258
260
|
reward_amount=amount, # Set reward_amount since this is a reward credit
|
|
259
261
|
free_amount=Decimal("0"), # No free credits involved
|
|
260
262
|
permanent_amount=Decimal("0"), # No permanent credits involved
|
|
263
|
+
agent_wallet_address=None, # No agent involved in reward
|
|
261
264
|
note=note,
|
|
262
265
|
)
|
|
263
266
|
session.add(event)
|
|
@@ -412,6 +415,7 @@ async def adjustment(
|
|
|
412
415
|
free_amount=free_amount,
|
|
413
416
|
reward_amount=reward_amount,
|
|
414
417
|
permanent_amount=permanent_amount,
|
|
418
|
+
agent_wallet_address=None, # No agent involved in adjustment
|
|
415
419
|
note=note,
|
|
416
420
|
)
|
|
417
421
|
session.add(event)
|
|
@@ -892,6 +896,10 @@ async def expense_message(
|
|
|
892
896
|
fee_agent_amount - fee_agent_free_amount - fee_agent_reward_amount
|
|
893
897
|
).quantize(FOURPLACES, rounding=ROUND_HALF_UP)
|
|
894
898
|
|
|
899
|
+
# Get agent wallet address
|
|
900
|
+
agent_data = await AgentData.get(agent.id)
|
|
901
|
+
agent_wallet_address = agent_data.evm_wallet_address if agent_data else None
|
|
902
|
+
|
|
895
903
|
event = CreditEventTable(
|
|
896
904
|
id=event_id,
|
|
897
905
|
account_id=user_account.id,
|
|
@@ -925,6 +933,7 @@ async def expense_message(
|
|
|
925
933
|
free_amount=free_amount,
|
|
926
934
|
reward_amount=reward_amount,
|
|
927
935
|
permanent_amount=permanent_amount,
|
|
936
|
+
agent_wallet_address=agent_wallet_address,
|
|
928
937
|
)
|
|
929
938
|
session.add(event)
|
|
930
939
|
await session.flush()
|
|
@@ -1268,6 +1277,10 @@ async def expense_skill(
|
|
|
1268
1277
|
skill_cost_info.fee_dev_amount - fee_dev_free_amount - fee_dev_reward_amount
|
|
1269
1278
|
).quantize(FOURPLACES, rounding=ROUND_HALF_UP)
|
|
1270
1279
|
|
|
1280
|
+
# Get agent wallet address
|
|
1281
|
+
agent_data = await AgentData.get(agent.id)
|
|
1282
|
+
agent_wallet_address = agent_data.evm_wallet_address if agent_data else None
|
|
1283
|
+
|
|
1271
1284
|
event = CreditEventTable(
|
|
1272
1285
|
id=event_id,
|
|
1273
1286
|
account_id=user_account.id,
|
|
@@ -1309,6 +1322,7 @@ async def expense_skill(
|
|
|
1309
1322
|
free_amount=free_amount,
|
|
1310
1323
|
reward_amount=reward_amount,
|
|
1311
1324
|
permanent_amount=permanent_amount,
|
|
1325
|
+
agent_wallet_address=agent_wallet_address,
|
|
1312
1326
|
)
|
|
1313
1327
|
session.add(event)
|
|
1314
1328
|
await session.flush()
|
|
@@ -1452,6 +1466,7 @@ async def refill_free_credits_for_account(
|
|
|
1452
1466
|
free_amount=amount_to_add, # Set free_amount since this is a free credit refill
|
|
1453
1467
|
reward_amount=Decimal("0"), # No reward credits involved
|
|
1454
1468
|
permanent_amount=Decimal("0"), # No permanent credits involved
|
|
1469
|
+
agent_wallet_address=None, # No agent involved in refill
|
|
1455
1470
|
note=f"Hourly free credits refill of {amount_to_add}",
|
|
1456
1471
|
)
|
|
1457
1472
|
session.add(event)
|
|
@@ -1675,6 +1690,10 @@ async def expense_summarize(
|
|
|
1675
1690
|
fee_agent_amount - fee_agent_free_amount - fee_agent_reward_amount
|
|
1676
1691
|
).quantize(FOURPLACES, rounding=ROUND_HALF_UP)
|
|
1677
1692
|
|
|
1693
|
+
# Get agent wallet address
|
|
1694
|
+
agent_data = await AgentData.get(agent.id)
|
|
1695
|
+
agent_wallet_address = agent_data.evm_wallet_address if agent_data else None
|
|
1696
|
+
|
|
1678
1697
|
event = CreditEventTable(
|
|
1679
1698
|
id=event_id,
|
|
1680
1699
|
account_id=user_account.id,
|
|
@@ -1707,6 +1726,7 @@ async def expense_summarize(
|
|
|
1707
1726
|
free_amount=free_amount,
|
|
1708
1727
|
reward_amount=reward_amount,
|
|
1709
1728
|
permanent_amount=permanent_amount,
|
|
1729
|
+
agent_wallet_address=agent_wallet_address,
|
|
1710
1730
|
)
|
|
1711
1731
|
session.add(event)
|
|
1712
1732
|
|
intentkit/models/credit.py
CHANGED
|
@@ -508,6 +508,7 @@ class CreditAccount(BaseModel):
|
|
|
508
508
|
free_amount=free_quota, # Set free_amount since this is a free credit refill
|
|
509
509
|
reward_amount=Decimal("0"), # No reward credits involved
|
|
510
510
|
permanent_amount=Decimal("0"), # No permanent credits involved
|
|
511
|
+
agent_wallet_address=None, # No agent involved in initial refill
|
|
511
512
|
note="Initial refill",
|
|
512
513
|
)
|
|
513
514
|
session.add(event)
|
|
@@ -712,6 +713,10 @@ class CreditEventTable(Base):
|
|
|
712
713
|
String,
|
|
713
714
|
nullable=True,
|
|
714
715
|
)
|
|
716
|
+
agent_wallet_address = Column(
|
|
717
|
+
String,
|
|
718
|
+
nullable=True,
|
|
719
|
+
)
|
|
715
720
|
start_message_id = Column(
|
|
716
721
|
String,
|
|
717
722
|
nullable=True,
|
|
@@ -896,6 +901,10 @@ class CreditEvent(BaseModel):
|
|
|
896
901
|
agent_id: Annotated[
|
|
897
902
|
Optional[str], Field(None, description="ID of the agent if applicable")
|
|
898
903
|
]
|
|
904
|
+
agent_wallet_address: Annotated[
|
|
905
|
+
Optional[str],
|
|
906
|
+
Field(None, description="Wallet address of the agent if applicable"),
|
|
907
|
+
]
|
|
899
908
|
start_message_id: Annotated[
|
|
900
909
|
Optional[str],
|
|
901
910
|
Field(None, description="ID of the starting message if applicable"),
|
intentkit/skills/acolyt/ask.py
CHANGED
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
import logging
|
|
2
|
-
from typing import Dict, Type
|
|
2
|
+
from typing import Dict, Literal, Type
|
|
3
3
|
|
|
4
4
|
import httpx
|
|
5
5
|
from langchain_core.runnables import RunnableConfig
|
|
6
6
|
from pydantic import BaseModel, Field
|
|
7
|
-
from typing_extensions import Literal
|
|
8
7
|
|
|
9
8
|
from intentkit.skills.acolyt.base import AcolytBaseTool
|
|
10
9
|
|
intentkit/skills/cdp/__init__.py
CHANGED
|
@@ -24,10 +24,12 @@ from intentkit.clients import CdpClient, get_cdp_client
|
|
|
24
24
|
from intentkit.skills.base import SkillConfig, SkillState
|
|
25
25
|
from intentkit.skills.cdp.base import CDPBaseTool
|
|
26
26
|
from intentkit.skills.cdp.get_balance import GetBalance
|
|
27
|
+
from intentkit.skills.cdp.swap import Swap
|
|
27
28
|
|
|
28
29
|
|
|
29
30
|
class SkillStates(TypedDict):
|
|
30
31
|
get_balance: SkillState
|
|
32
|
+
swap: SkillState
|
|
31
33
|
WalletActionProvider_get_balance: SkillState
|
|
32
34
|
WalletActionProvider_get_wallet_details: SkillState
|
|
33
35
|
WalletActionProvider_native_transfer: SkillState
|
|
@@ -121,6 +123,15 @@ async def get_skills(
|
|
|
121
123
|
)
|
|
122
124
|
)
|
|
123
125
|
continue
|
|
126
|
+
elif skill == "swap" or skill.endswith("_trade"):
|
|
127
|
+
# Add the custom Swap skill, "trade" is backword compatible
|
|
128
|
+
tools.append(
|
|
129
|
+
Swap(
|
|
130
|
+
agent_id=agent_id,
|
|
131
|
+
skill_store=store,
|
|
132
|
+
)
|
|
133
|
+
)
|
|
134
|
+
continue
|
|
124
135
|
for tool in cdp_tools:
|
|
125
136
|
if tool.name.endswith(skill):
|
|
126
137
|
tool.handle_tool_error = lambda e: f"tool error: {e}"
|
intentkit/skills/cdp/schema.json
CHANGED
|
@@ -33,6 +33,22 @@
|
|
|
33
33
|
"description": "Use coinbase API to get wallet balance, float result.",
|
|
34
34
|
"default": "private"
|
|
35
35
|
},
|
|
36
|
+
"swap": {
|
|
37
|
+
"type": "string",
|
|
38
|
+
"title": "CDP Wallet Swap",
|
|
39
|
+
"enum": [
|
|
40
|
+
"disabled",
|
|
41
|
+
"public",
|
|
42
|
+
"private"
|
|
43
|
+
],
|
|
44
|
+
"x-enum-title": [
|
|
45
|
+
"Disabled",
|
|
46
|
+
"Agent Owner + All Users",
|
|
47
|
+
"Agent Owner Only"
|
|
48
|
+
],
|
|
49
|
+
"description": "Use coinbase API to swap.",
|
|
50
|
+
"default": "disabled"
|
|
51
|
+
},
|
|
36
52
|
"WalletActionProvider_get_balance": {
|
|
37
53
|
"type": "string",
|
|
38
54
|
"title": "Normal Get Balance",
|
|
@@ -0,0 +1,121 @@
|
|
|
1
|
+
from typing import Optional, Type, Union
|
|
2
|
+
|
|
3
|
+
from pydantic import BaseModel, Field
|
|
4
|
+
|
|
5
|
+
from intentkit.abstracts.skill import SkillStoreABC
|
|
6
|
+
from intentkit.clients import get_cdp_client
|
|
7
|
+
from intentkit.skills.cdp.base import CDPBaseTool
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
class SwapInput(BaseModel):
|
|
11
|
+
"""Input for Swap tool."""
|
|
12
|
+
|
|
13
|
+
from_token: str = Field(
|
|
14
|
+
description="The contract address of the token to swap from (e.g., '0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913' for USDC on Base)"
|
|
15
|
+
)
|
|
16
|
+
to_token: str = Field(
|
|
17
|
+
description="The contract address of the token to swap to (e.g., '0x4200000000000000000000000000000000000006' for WETH on Base)"
|
|
18
|
+
)
|
|
19
|
+
from_amount: Union[str, int] = Field(
|
|
20
|
+
description="The amount to swap from in smallest unit (e.g., 1000000 for 1 USDC with 6 decimals)"
|
|
21
|
+
)
|
|
22
|
+
slippage_bps: Optional[int] = Field(
|
|
23
|
+
default=100,
|
|
24
|
+
description="Maximum slippage in basis points (100 = 1%). Defaults to 100 (1%)",
|
|
25
|
+
)
|
|
26
|
+
|
|
27
|
+
|
|
28
|
+
class Swap(CDPBaseTool):
|
|
29
|
+
"""Tool for swapping tokens using CDP wallet.
|
|
30
|
+
|
|
31
|
+
This tool uses the CDP API to execute token swaps on supported networks.
|
|
32
|
+
It wraps the swap functionality from the EVM account.
|
|
33
|
+
|
|
34
|
+
Attributes:
|
|
35
|
+
name: The name of the tool.
|
|
36
|
+
description: A description of what the tool does.
|
|
37
|
+
args_schema: The schema for the tool's input arguments.
|
|
38
|
+
"""
|
|
39
|
+
|
|
40
|
+
agent_id: str
|
|
41
|
+
skill_store: SkillStoreABC
|
|
42
|
+
|
|
43
|
+
name: str = "cdp_swap"
|
|
44
|
+
description: str = (
|
|
45
|
+
"This tool will swap tokens using the CDP wallet. "
|
|
46
|
+
"It supports swapping between any ERC-20 tokens on supported networks (Base and Ethereum). "
|
|
47
|
+
"You need to provide the contract addresses of both tokens and the amount to swap. "
|
|
48
|
+
"The amount should be in the smallest unit of the token (e.g., wei for ETH, or atomic units for ERC-20 tokens). "
|
|
49
|
+
"Common token addresses on Base: USDC=0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913, WETH=0x4200000000000000000000000000000000000006. "
|
|
50
|
+
"The tool will automatically handle gas estimation and transaction submission."
|
|
51
|
+
)
|
|
52
|
+
args_schema: Type[BaseModel] = SwapInput
|
|
53
|
+
|
|
54
|
+
async def _arun(
|
|
55
|
+
self,
|
|
56
|
+
from_token: str,
|
|
57
|
+
to_token: str,
|
|
58
|
+
from_amount: Union[str, int],
|
|
59
|
+
slippage_bps: Optional[int] = 100,
|
|
60
|
+
) -> str:
|
|
61
|
+
"""Async implementation of the tool to swap tokens.
|
|
62
|
+
|
|
63
|
+
Args:
|
|
64
|
+
from_token (str): The contract address of the token to swap from.
|
|
65
|
+
to_token (str): The contract address of the token to swap to.
|
|
66
|
+
from_amount (Union[str, int]): The amount to swap from in smallest unit.
|
|
67
|
+
slippage_bps (Optional[int]): Maximum slippage in basis points. Defaults to 100 (1%).
|
|
68
|
+
|
|
69
|
+
Returns:
|
|
70
|
+
str: A message containing the swap result or error message.
|
|
71
|
+
"""
|
|
72
|
+
try:
|
|
73
|
+
# Get CDP client and network information
|
|
74
|
+
cdp_client = await get_cdp_client(self.agent_id, self.skill_store)
|
|
75
|
+
provider = await cdp_client.get_wallet_provider()
|
|
76
|
+
provider_config = await cdp_client.get_provider_config()
|
|
77
|
+
network_id = provider_config.network_id
|
|
78
|
+
|
|
79
|
+
# Map network_id to the format expected by the swap API
|
|
80
|
+
network_mapping = {
|
|
81
|
+
"base-mainnet": "base",
|
|
82
|
+
"ethereum-mainnet": "ethereum",
|
|
83
|
+
}
|
|
84
|
+
api_network = network_mapping.get(network_id, network_id)
|
|
85
|
+
|
|
86
|
+
# Validate network is supported
|
|
87
|
+
supported_networks = ["base", "ethereum"]
|
|
88
|
+
if api_network not in supported_networks:
|
|
89
|
+
return f"Error: Network {api_network} is not supported for swaps. Supported networks: {', '.join(supported_networks)}"
|
|
90
|
+
|
|
91
|
+
# Get the EVM account
|
|
92
|
+
client = provider.get_client()
|
|
93
|
+
async with client:
|
|
94
|
+
account = await client.evm.get_account(provider.get_address())
|
|
95
|
+
|
|
96
|
+
# Import AccountSwapOptions here to avoid circular imports
|
|
97
|
+
from cdp.actions.evm.swap.types import AccountSwapOptions
|
|
98
|
+
|
|
99
|
+
# Create swap options
|
|
100
|
+
swap_options = AccountSwapOptions(
|
|
101
|
+
network=api_network,
|
|
102
|
+
from_token=from_token,
|
|
103
|
+
to_token=to_token,
|
|
104
|
+
from_amount=str(from_amount),
|
|
105
|
+
slippage_bps=slippage_bps,
|
|
106
|
+
)
|
|
107
|
+
|
|
108
|
+
# Execute the swap
|
|
109
|
+
result = await account.swap(swap_options)
|
|
110
|
+
|
|
111
|
+
return (
|
|
112
|
+
f"Swap executed successfully!\n"
|
|
113
|
+
f"Transaction hash: {result.transaction_hash}\n"
|
|
114
|
+
f"Swapped from {from_token} to {to_token}\n"
|
|
115
|
+
f"Amount: {from_amount} (smallest units)\n"
|
|
116
|
+
f"Network: {api_network}\n"
|
|
117
|
+
f"Slippage tolerance: {slippage_bps} basis points ({slippage_bps / 100 if slippage_bps else 0}%)"
|
|
118
|
+
)
|
|
119
|
+
|
|
120
|
+
except Exception as e:
|
|
121
|
+
return f"Error executing swap: {e!s}"
|
|
@@ -32,7 +32,7 @@ class ReadAgentApiKey(SystemBaseTool):
|
|
|
32
32
|
"Make sure to tell the user the base URL and endpoint. "
|
|
33
33
|
"Tell user in OpenAI sdk or Desktop client like Cherry Studio, input the base URL and API key. "
|
|
34
34
|
"Always use markdown code block to wrap the API keys, base URL, and endpoint. "
|
|
35
|
-
"Tell user to check more doc in https://github.com/crestalnetwork/intentkit/blob/main/docs/
|
|
35
|
+
"Tell user to check more doc in https://github.com/crestalnetwork/intentkit/blob/main/docs/agent_api.md "
|
|
36
36
|
)
|
|
37
37
|
args_schema = ReadAgentApiKeyInput
|
|
38
38
|
|
|
@@ -34,7 +34,7 @@ class RegenerateAgentApiKey(SystemBaseTool):
|
|
|
34
34
|
"Make sure to tell the user the base URL and endpoint. "
|
|
35
35
|
"Tell user in OpenAI sdk or Desktop client like Cherry Studio, input the base URL and API key. "
|
|
36
36
|
"Always use markdown code block to wrap the API keys, base URL, and endpoint. "
|
|
37
|
-
"Tell user to check more doc in https://github.com/crestalnetwork/intentkit/blob/main/docs/
|
|
37
|
+
"Tell user to check more doc in https://github.com/crestalnetwork/intentkit/blob/main/docs/agent_api.md "
|
|
38
38
|
)
|
|
39
39
|
args_schema = RegenerateAgentApiKeyInput
|
|
40
40
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: intentkit
|
|
3
|
-
Version: 0.6.
|
|
3
|
+
Version: 0.6.3.dev1
|
|
4
4
|
Summary: Intent-based AI Agent Platform - Core Package
|
|
5
5
|
Project-URL: Homepage, https://github.com/crestal-network/intentkit
|
|
6
6
|
Project-URL: Repository, https://github.com/crestal-network/intentkit
|
|
@@ -38,50 +38,27 @@ Classifier: Programming Language :: Python :: 3.12
|
|
|
38
38
|
Classifier: Topic :: Scientific/Engineering :: Artificial Intelligence
|
|
39
39
|
Classifier: Topic :: Software Development :: Libraries :: Python Modules
|
|
40
40
|
Requires-Python: >=3.12
|
|
41
|
-
Requires-Dist:
|
|
41
|
+
Requires-Dist: aiohttp>=3.11.16
|
|
42
42
|
Requires-Dist: aiosqlite>=0.21.0
|
|
43
|
-
Requires-Dist: alembic>=1.14.0
|
|
44
|
-
Requires-Dist: anyio>=4.8.0
|
|
45
|
-
Requires-Dist: apscheduler>=3.11.0
|
|
46
43
|
Requires-Dist: asyncpg>=0.30.0
|
|
47
44
|
Requires-Dist: aws-secretsmanager-caching>=1.1.3
|
|
48
|
-
Requires-Dist:
|
|
45
|
+
Requires-Dist: bip32>=2.0.0
|
|
49
46
|
Requires-Dist: boto3<2.0.0,>=1.37.23
|
|
50
47
|
Requires-Dist: botocore>=1.35.97
|
|
51
|
-
Requires-Dist:
|
|
52
|
-
Requires-Dist: coinbase-agentkit
|
|
48
|
+
Requires-Dist: cdp-sdk<2,>=1.6.1
|
|
49
|
+
Requires-Dist: coinbase-agentkit-langchain>=0.5.0
|
|
50
|
+
Requires-Dist: coinbase-agentkit>=0.6.0
|
|
53
51
|
Requires-Dist: cron-validator<2.0.0,>=1.0.8
|
|
54
52
|
Requires-Dist: epyxid>=0.3.3
|
|
55
|
-
Requires-Dist:
|
|
53
|
+
Requires-Dist: eth-keys>=0.4.0
|
|
54
|
+
Requires-Dist: eth-utils>=2.1.0
|
|
56
55
|
Requires-Dist: fastapi>=0.115.8
|
|
57
56
|
Requires-Dist: filetype<2.0.0,>=1.2.0
|
|
58
|
-
Requires-Dist:
|
|
59
|
-
Requires-Dist: goat-sdk-plugin-1inch
|
|
60
|
-
Requires-Dist: goat-sdk-plugin-allora
|
|
61
|
-
Requires-Dist: goat-sdk-plugin-coingecko
|
|
62
|
-
Requires-Dist: goat-sdk-plugin-dexscreener
|
|
63
|
-
Requires-Dist: goat-sdk-plugin-erc20
|
|
64
|
-
Requires-Dist: goat-sdk-plugin-farcaster
|
|
65
|
-
Requires-Dist: goat-sdk-plugin-jsonrpc
|
|
66
|
-
Requires-Dist: goat-sdk-plugin-jupiter
|
|
67
|
-
Requires-Dist: goat-sdk-plugin-nansen
|
|
68
|
-
Requires-Dist: goat-sdk-plugin-opensea
|
|
69
|
-
Requires-Dist: goat-sdk-plugin-rugcheck
|
|
70
|
-
Requires-Dist: goat-sdk-plugin-spl-token
|
|
71
|
-
Requires-Dist: goat-sdk-plugin-superfluid
|
|
72
|
-
Requires-Dist: goat-sdk-plugin-uniswap
|
|
73
|
-
Requires-Dist: goat-sdk-wallet-crossmint
|
|
74
|
-
Requires-Dist: goat-sdk-wallet-evm
|
|
75
|
-
Requires-Dist: goat-sdk-wallet-solana
|
|
76
|
-
Requires-Dist: goat-sdk-wallet-web3
|
|
77
|
-
Requires-Dist: goat-sdk>=0.1.4
|
|
78
|
-
Requires-Dist: gunicorn>=23.0.0
|
|
79
|
-
Requires-Dist: jsonref>=1.1.0
|
|
57
|
+
Requires-Dist: httpx>=0.28.1
|
|
80
58
|
Requires-Dist: langchain-community>=0.3.19
|
|
81
59
|
Requires-Dist: langchain-core>=0.3.43
|
|
82
60
|
Requires-Dist: langchain-mcp-adapters>=0.0.11
|
|
83
61
|
Requires-Dist: langchain-openai>=0.3.8
|
|
84
|
-
Requires-Dist: langchain-postgres>=0.0.13
|
|
85
62
|
Requires-Dist: langchain-text-splitters>=0.3.8
|
|
86
63
|
Requires-Dist: langchain-xai>=0.2.1
|
|
87
64
|
Requires-Dist: langchain<0.4.0,>=0.3.25
|
|
@@ -92,25 +69,24 @@ Requires-Dist: langgraph>=0.4.3
|
|
|
92
69
|
Requires-Dist: langmem>=0.0.27
|
|
93
70
|
Requires-Dist: mypy-boto3-s3<2.0.0,>=1.37.24
|
|
94
71
|
Requires-Dist: openai>=1.59.6
|
|
95
|
-
Requires-Dist: pgvector>=0.3.6
|
|
96
72
|
Requires-Dist: pillow<12.0.0,>=11.1.0
|
|
97
73
|
Requires-Dist: psycopg-pool>=3.2.4
|
|
98
|
-
Requires-Dist:
|
|
99
|
-
Requires-Dist: psycopg>=3.2.3
|
|
100
|
-
Requires-Dist: pydantic-settings>=2.8.1
|
|
74
|
+
Requires-Dist: psycopg>=3.2.9
|
|
101
75
|
Requires-Dist: pydantic>=2.10.6
|
|
102
76
|
Requires-Dist: python-dotenv>=1.0.1
|
|
103
|
-
Requires-Dist: python-multipart>=0.0.20
|
|
104
77
|
Requires-Dist: pytz>=2025.1
|
|
105
78
|
Requires-Dist: pyyaml>=6.0.2
|
|
106
79
|
Requires-Dist: redis<7.0.0,>=5.2.1
|
|
80
|
+
Requires-Dist: requests-oauthlib>=2.0.0
|
|
107
81
|
Requires-Dist: requests>=2.32.3
|
|
108
|
-
Requires-Dist: sentry-sdk[fastapi]>=2.20.0
|
|
109
82
|
Requires-Dist: slack-sdk>=3.34.0
|
|
110
83
|
Requires-Dist: sqlalchemy[asyncio]>=2.0.37
|
|
111
|
-
Requires-Dist:
|
|
84
|
+
Requires-Dist: starlette>=0.47.1
|
|
85
|
+
Requires-Dist: supabase>=2.16.0
|
|
86
|
+
Requires-Dist: tenacity>=9.1.2
|
|
112
87
|
Requires-Dist: tweepy[async]>=4.15.0
|
|
113
88
|
Requires-Dist: uvicorn<1.0.0,>=0.34.0
|
|
89
|
+
Requires-Dist: web3>=7.10.0
|
|
114
90
|
Description-Content-Type: text/markdown
|
|
115
91
|
|
|
116
92
|
# IntentKit
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
intentkit/__init__.py,sha256=
|
|
1
|
+
intentkit/__init__.py,sha256=KGtBmzaxW6AbedYuRBHrti62uvBUoegZCrOn6UdojyQ,383
|
|
2
2
|
intentkit/abstracts/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
3
3
|
intentkit/abstracts/agent.py,sha256=108gb5W8Q1Sy4G55F2_ZFv2-_CnY76qrBtpIr0Oxxqk,1489
|
|
4
4
|
intentkit/abstracts/api.py,sha256=ZUc24vaQvQVbbjznx7bV0lbbQxdQPfEV8ZxM2R6wZWo,166
|
|
@@ -9,14 +9,14 @@ intentkit/abstracts/skill.py,sha256=WS8G_XP0Ukw1eUB-dhbx6FrJUbvV4tqzRnkWa2dt9ck,
|
|
|
9
9
|
intentkit/abstracts/twitter.py,sha256=cEtP7ygR_b-pHdc9i8kBuyooz1cPoGUGwsBHDpowJyY,1262
|
|
10
10
|
intentkit/clients/__init__.py,sha256=sQ_6_bRC2MPWLPH-skQ3qsEe8ce-dUGL7i8VJOautHg,298
|
|
11
11
|
intentkit/clients/cdp.py,sha256=_CkvnBkzdq7-sFMGct4lz85FpaOoHxOGstWubhClzrA,5921
|
|
12
|
-
intentkit/clients/twitter.py,sha256=
|
|
12
|
+
intentkit/clients/twitter.py,sha256=gT7lXYAeRACZGYrTOPjoGoVNWAC1-qn9gkASVTeDL4M,19106
|
|
13
13
|
intentkit/config/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
14
14
|
intentkit/config/config.py,sha256=6RreVvQH1xuHVOnIJ3AcaRYzdMw1RLo0vYYtvPKvTds,7453
|
|
15
15
|
intentkit/core/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
16
16
|
intentkit/core/agent.py,sha256=PTHsFV_EbsfPUcTI0ErkebWurjxVykP9ISbNUsqV44Q,7764
|
|
17
17
|
intentkit/core/api.py,sha256=3GIMJpwduLUSbVPNW6mQVxZncYHH3OlLwdiqFtYtEAE,1208
|
|
18
18
|
intentkit/core/client.py,sha256=rIwtJVVm-7piXtFNDbeykt9vWdNTecgjW0aA3N-lHnM,1495
|
|
19
|
-
intentkit/core/credit.py,sha256=
|
|
19
|
+
intentkit/core/credit.py,sha256=vLT47NlLrGyvSU1OP8dkVXV5_VHqRNSeAK5t1FqSSYs,61742
|
|
20
20
|
intentkit/core/engine.py,sha256=ZoMk8fBUg1fqbELT8Pi8vB667ytFqAT4mQfUNt5g_H0,41192
|
|
21
21
|
intentkit/core/node.py,sha256=RqAdcR1Fcpgw4k7q9l1Sry8LgcuZWdNxSjOHDcoavCI,9108
|
|
22
22
|
intentkit/core/prompt.py,sha256=RfLhlUktkB2kCr3wfldqq6ZP2l8heZIMc8jVp31KIyQ,3631
|
|
@@ -28,7 +28,7 @@ intentkit/models/app_setting.py,sha256=WgW-9t0EbiVemRLrVaC6evdfRU5QFSDK0elsnUU5n
|
|
|
28
28
|
intentkit/models/base.py,sha256=o-zRjVrak-f5Jokdvj8BjLm8gcC3yYiYMCTLegwT2lA,185
|
|
29
29
|
intentkit/models/chat.py,sha256=2P9dPWEti9f7XbO6L6Kp89lcYuyymSwqzxhL4GfBmBc,18019
|
|
30
30
|
intentkit/models/conversation.py,sha256=nrbDIw-3GK5BYi_xkI15FLdx4a6SNrFK8wfAGLCsrqk,9032
|
|
31
|
-
intentkit/models/credit.py,sha256=
|
|
31
|
+
intentkit/models/credit.py,sha256=95buGlZwIuoSPasZcqYEKvdrnUiUe2RzJCR3a2rvQvU,42397
|
|
32
32
|
intentkit/models/db.py,sha256=2OpdTjQWUM9FkDP8Ni0mGLeVJ5q9ah3bGlGe9-IzDp0,3999
|
|
33
33
|
intentkit/models/db_mig.py,sha256=vT6Tanm-BHC2T7dTztuB1UG494EFBAlHADKsNzR6xaQ,3577
|
|
34
34
|
intentkit/models/generator.py,sha256=lyZu9U9rZUGkqd_QT5SAhay9DY358JJY8EhDSpN8I1M,10298
|
|
@@ -41,7 +41,7 @@ intentkit/skills/base.py,sha256=nPHX8kZ-r5ffbCGH6Tnh0KwGWlF1D4zMmnjsFf9iScA,6677
|
|
|
41
41
|
intentkit/skills/skills.toml,sha256=iFMn_UmdFFCk4HTHolpSv6Ve6O-iRckJtxVcZ5EjxQM,2634
|
|
42
42
|
intentkit/skills/acolyt/__init__.py,sha256=qHQXFlqyyx4deRxC0rts_ZEEpDVV-vWXPncqI_ZMOi4,2074
|
|
43
43
|
intentkit/skills/acolyt/acolyt.jpg,sha256=CwrrouzXzYvnHi1rprYruvZqPopG06ppMczEZmZ7D2s,11559
|
|
44
|
-
intentkit/skills/acolyt/ask.py,sha256=
|
|
44
|
+
intentkit/skills/acolyt/ask.py,sha256=EHIg73vZBn1s3kMUvS04QnJCAX9HBhjwBJ9-r7OoEwI,6104
|
|
45
45
|
intentkit/skills/acolyt/base.py,sha256=IJp8RDjYe14hkkPKiiWyPJ-o_AdXbJmhZMkRLVNUieU,916
|
|
46
46
|
intentkit/skills/acolyt/schema.json,sha256=sKwLHLQOfGdyh7BupUpk5fJxopO8_svg1VRhK1H1S8k,2760
|
|
47
47
|
intentkit/skills/aixbt/README.md,sha256=OPZEZnYo4fwj37CkDC7onB1bqXR_GwAGAcusd-gZrGI,2499
|
|
@@ -63,11 +63,12 @@ intentkit/skills/carv/fetch_news.py,sha256=-xCWPvdVQxI0tEynR8mnjNEFpDkE4k4vNo1A-
|
|
|
63
63
|
intentkit/skills/carv/onchain_query.py,sha256=EYV7N2Y-CisyhNVyUm2NbJhdikeFg0Y_a6lToJ5iqDM,6371
|
|
64
64
|
intentkit/skills/carv/schema.json,sha256=oSReeG50ZJTOxSRniQBJW6KfilscZfp66PiBVOjphS4,5021
|
|
65
65
|
intentkit/skills/carv/token_info_and_price.py,sha256=R7M5-nkjrauvxaNkORYtLcP9yOYj8PvYu1xRkOBT6lU,4275
|
|
66
|
-
intentkit/skills/cdp/__init__.py,sha256=
|
|
66
|
+
intentkit/skills/cdp/__init__.py,sha256=0OAYGSW_8u1kzV7mPxdyLVSlYWv_cQeQ87pVZPgwTsk,4772
|
|
67
67
|
intentkit/skills/cdp/base.py,sha256=BcleKSXm0oNcHYky4uUPCJ3roXxMeTJs2OUS-8MkfMI,581
|
|
68
68
|
intentkit/skills/cdp/cdp.png,sha256=dxPF6jPbKVfxJNMvbGTmBhXM-rSDvweF06txoX1cIM4,4425
|
|
69
69
|
intentkit/skills/cdp/get_balance.py,sha256=-mRFJjlc2gQ4LZRMqD6HZqyR_y_rsMl1HlVONoE0kIw,4473
|
|
70
|
-
intentkit/skills/cdp/schema.json,sha256=
|
|
70
|
+
intentkit/skills/cdp/schema.json,sha256=42RIctR_VUwrsIKelEdCreTmVgfUTF9pu3d7gVTe0DQ,12191
|
|
71
|
+
intentkit/skills/cdp/swap.py,sha256=QO476onHskkv5xYoLlV56iU_NDg4q9KVntmknK5EL5Y,4983
|
|
71
72
|
intentkit/skills/chainlist/README.md,sha256=FEVQObs2W_oL2kyV-vZpHNwZCCgqm5Kt0sv0GD_Xo1M,958
|
|
72
73
|
intentkit/skills/chainlist/__init__.py,sha256=2aRC-jXW3WYiR_-RM-_Ls1lby_54ZemZ6qtggntGa-U,1502
|
|
73
74
|
intentkit/skills/chainlist/base.py,sha256=rRhrXcdg06qAYE0uIiL9NctpODuTIu51Eyxp4UVtflU,599
|
|
@@ -292,8 +293,8 @@ intentkit/skills/supabase/update_data.py,sha256=Hbwsoa52GZNTPIhWdR9vj9VlcPRUn_vC
|
|
|
292
293
|
intentkit/skills/supabase/upsert_data.py,sha256=JgKLFPcQkUwnQhqTZojT4Ae53hYULeGEkQ1gxZJEe-c,2538
|
|
293
294
|
intentkit/skills/system/__init__.py,sha256=y5sBakdOL1vtXV8DNn-g_MN11CrJ8QrOceoJjD5MzXs,2402
|
|
294
295
|
intentkit/skills/system/base.py,sha256=Sm4lSNgbxwGK5YimnBfwi3Hc8E1EwSMZIXsCJbIPiLM,700
|
|
295
|
-
intentkit/skills/system/read_agent_api_key.py,sha256=
|
|
296
|
-
intentkit/skills/system/regenerate_agent_api_key.py,sha256=
|
|
296
|
+
intentkit/skills/system/read_agent_api_key.py,sha256=PmTi4dJ1yDsowPHk4iT0bR-g9Il_UOg895a8aWvCrUQ,3517
|
|
297
|
+
intentkit/skills/system/regenerate_agent_api_key.py,sha256=BaF9l3zDyzJNLoVT8ZAaZTmpXaDwumLW8VO8RLVjLyI,3177
|
|
297
298
|
intentkit/skills/system/schema.json,sha256=4lv144DEDz9m1NYQdTgke3nDyCrVsGm82QiIoLbIRww,1462
|
|
298
299
|
intentkit/skills/system/system.svg,sha256=PVbC6r6rOhvht0lB1fcxDNTcbMUa7haHAkJ8rxp7gm0,3740
|
|
299
300
|
intentkit/skills/tavily/README.md,sha256=VagMkuHrS_ge2Sir9M9CoeqmWc_rysKhTO9-LGICQsA,2840
|
|
@@ -389,7 +390,7 @@ intentkit/utils/random.py,sha256=DymMxu9g0kuQLgJUqalvgksnIeLdS-v0aRk5nQU0mLI,452
|
|
|
389
390
|
intentkit/utils/s3.py,sha256=9trQNkKQ5VgxWsewVsV8Y0q_pXzGRvsCYP8xauyUYkg,8549
|
|
390
391
|
intentkit/utils/slack_alert.py,sha256=s7UpRgyzLW7Pbmt8cKzTJgMA9bm4EP-1rQ5KXayHu6E,2264
|
|
391
392
|
intentkit/utils/tx.py,sha256=2yLLGuhvfBEY5n_GJ8wmIWLCzn0FsYKv5kRNzw_sLUI,1454
|
|
392
|
-
intentkit-0.6.
|
|
393
|
-
intentkit-0.6.
|
|
394
|
-
intentkit-0.6.
|
|
395
|
-
intentkit-0.6.
|
|
393
|
+
intentkit-0.6.3.dev1.dist-info/METADATA,sha256=tNGOvsSUJWxr1-HbwL4K18zQnWxO84AXL5LFpe0p_h0,6307
|
|
394
|
+
intentkit-0.6.3.dev1.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
|
|
395
|
+
intentkit-0.6.3.dev1.dist-info/licenses/LICENSE,sha256=Bln6DhK-LtcO4aXy-PBcdZv2f24MlJFm_qn222biJtE,1071
|
|
396
|
+
intentkit-0.6.3.dev1.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|