Skip to content

Commit

Permalink
fix(docs): fix gh issues (#928)
Browse files Browse the repository at this point in the history
  • Loading branch information
gautamgambhir97 authored Sep 6, 2024
1 parent c9496a2 commit b1db9b4
Show file tree
Hide file tree
Showing 10 changed files with 15 additions and 12 deletions.
2 changes: 1 addition & 1 deletion pages/examples/intermediate/coin-toss.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ To enable this on [DeltaV ↗️](/concepts/ai-engine/deltav) you will need to c
```python copy filename="agent.py"
import random
# third party modules used in this example
from pydantic import Field
from uagents import Field
from ai_engine import UAgentResponse, UAgentResponseType


Expand Down
2 changes: 1 addition & 1 deletion pages/examples/intermediate/dice-roll.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ To enable this on [DeltaV ↗️](/concepts/ai-engine/deltav) you will need to c
```py copy filename="agent.py"
import random
# third party modules used in this example
from pydantic import Field
from uagents import Field
from ai_engine import UAgentResponse, UAgentResponseType


Expand Down
2 changes: 1 addition & 1 deletion pages/examples/intermediate/local-agent-langchain.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ from langchain_community.tools import WikipediaQueryRun
from langchain_community.utilities import WikipediaAPIWrapper
from uagents.setup import fund_agent_if_low
from uagents import Agent, Context, Protocol, Model
from pydantic import Field
from uagents import Field
from ai_engine import UAgentResponse, UAgentResponseType

# Extend your protocol with Wikipedia data fetching
Expand Down
2 changes: 1 addition & 1 deletion pages/examples/intermediate/local-agent-registration.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ This file can be run on any platform supporting Python, with the necessary insta
from uagents.setup import fund_agent_if_low
from uagents import Agent, Context, Protocol, Model
import random
from pydantic import Field
from uagents import Field
from ai_engine import UAgentResponse, UAgentResponseType
import sys

Expand Down
2 changes: 1 addition & 1 deletion pages/guides/agents/intermediate/agent-functions.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ This system is pretty simple and makes you get started as quickly as possible. Y
from uagents.setup import fund_agent_if_low
from uagents import Agent, Context, Protocol, Model
import random
from pydantic import Field
from uagents import Field
from ai_engine import UAgentResponse, UAgentResponseType
import sys

Expand Down
7 changes: 5 additions & 2 deletions pages/guides/agents/intermediate/mailbox.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -124,13 +124,16 @@ Let's create and run a second agent to message Alice every 3 seconds. You need t
class Message(Model):
message: str

agent_2 = Agent(name="agent_2", seed="agent_2 recovery phrase")
agent_2 = Agent(name="agent_2", seed="agent_2 recovery phrase", port=8001, endpoint="http://localhost:8001/submit")

ALICE_ADDRESS = "add_address_of_alice_agent"

@agent_2.on_interval(period=3.0)
async def send_message(ctx: Context):
await ctx.send([ALICE_ADDRESS], Message(message=f"hello {datetime.datetime.now()}"))
await ctx.send(ALICE_ADDRESS, Message(message=f"hello {datetime.today().date()}"))

if __name__ == "__main__":
agent.run()

```

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ Consider the following Agent:
from uagents.setup import fund_agent_if_low
from uagents import Agent, Context, Protocol, Model
import random
from pydantic import Field
from uagents import Field
from ai_engine import UAgentResponse, UAgentResponseType
import sys

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ After clicking on the row of your newly created agent, you should be able to see

import random
# third party modules used in this example
from pydantic import Field
from uagents import Field
from ai_engine import UAgentResponse, UAgentResponseType


Expand Down
4 changes: 2 additions & 2 deletions pages/guides/agentverse/avctl/avctl-hosting.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -125,9 +125,9 @@ Supported Packages:
- python: >=3.11,<3.12
- requests: ^2.28.2
- cosmpy: ^0.9.2
- uagents: ^0.11.0
- uagents-ai-engine: ^0.1.3
- uagents: ^0.15.2
- pydantic: ^1.10.5
- uagents-ai-engine: ^0.5.0
- mysqlclient: ^2.2.0
- pymongo: ^4.6.0
abc@xyz-MacBook-Pro myagents %
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ After clicking on the row of your newly created agent, you should be able to see

import random
# third party modules used in this example
from pydantic import Field
from uagents import Field
from ai_engine import UAgentResponse, UAgentResponseType

class DiceRoll(Model):
Expand Down

0 comments on commit b1db9b4

Please sign in to comment.