Skip to content

Commit 450c9b4

Browse files
authored
Merge branch 'main' into dependabot/pip/ruff-0.15.1
2 parents b369317 + 371f721 commit 450c9b4

25 files changed

Lines changed: 148 additions & 70 deletions

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Casey: IT Helpdesk Agent
22

3-
Meet Casey — an AI-powered IT helpdesk agent that lives in Slack. Casey can troubleshoot common issues, search knowledge base articles, reset passwords, check system status, and create support tickets, all without leaving the conversation.
3+
Meet Casey (they/them) — an AI-powered IT helpdesk agent that lives in Slack. Casey can troubleshoot common issues, search knowledge base articles, reset passwords, check system status, and create support tickets, all without leaving the conversation.
44

55
Built with [Bolt for Python](https://docs.slack.dev/tools/bolt-python/).
66

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"manifest": {
3-
"source": "remote"
3+
"source": "local"
44
},
55
"project_id": "f4a2c8e1-7b3d-4e9a-b5f6-2d8c1a0e3f7b"
66
}

openai-agents-sdk/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Casey: IT Helpdesk Agent (Bolt for Python and OpenAI Agents SDK)
22

3-
Meet Casey — an AI-powered IT helpdesk agent that lives in Slack. Casey can troubleshoot common issues, search knowledge base articles, reset passwords, check system status, and create support tickets, all without leaving the conversation.
3+
Meet Casey (they/them) — an AI-powered IT helpdesk agent that lives in Slack. Casey can troubleshoot common issues, search knowledge base articles, reset passwords, check system status, and create support tickets, all without leaving the conversation.
44

55
Built with [Bolt for Python](https://docs.slack.dev/tools/bolt-python/) and [OpenAI Agents SDK](https://openai.github.io/openai-agents-python/) using models from [OpenAI](https://openai.com).
66

openai-agents-sdk/agent/support_agent.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
- Confident but honest when you don't know something
2121
2222
## Formatting Rules
23-
- Use Slack mrkdwn syntax: *bold*, _italic_, `code`, ```code blocks```, > blockquotes
23+
- Use standard Markdown syntax: **bold**, _italic_, `code`, ```code blocks```, > blockquotes
2424
- Use bullet points for multi-step instructions
2525
- Keep responses concise — aim for helpful, not verbose
2626
- When referencing ticket IDs or system names, use `inline code`

openai-agents-sdk/agent/tools/knowledge_base.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,7 @@ async def search_knowledge_base(
122122
results = []
123123
for article in matches:
124124
results.append(
125-
f"*{article['title']}* ({article['article_id']})\n{article['content']}"
125+
f"**{article['title']}** ({article['article_id']})\n{article['content']}"
126126
)
127127

128128
return "\n\n---\n\n".join(results)

openai-agents-sdk/agent/tools/password_reset.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ async def trigger_password_reset(
1818
target_user: The username or email of the user whose password should be reset.
1919
"""
2020
return (
21-
f"Password reset initiated for *{target_user}*.\n\n"
21+
f"Password reset initiated for **{target_user}**.\n\n"
2222
f"A reset link has been sent to the email address on file. "
2323
f"The link will expire in 30 minutes.\n\n"
2424
f"_If the user doesn't receive the email within 5 minutes, "

openai-agents-sdk/agent/tools/system_status.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ async def check_system_status(
7676
}.get(info["status"], ":white_circle:")
7777

7878
return (
79-
f"*{info['name']}* {status_emoji} `{info['status'].upper()}`\n"
79+
f"**{info['name']}** {status_emoji} `{info['status'].upper()}`\n"
8080
f"{info['details']}"
8181
)
8282

openai-agents-sdk/agent/tools/ticket.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -29,11 +29,11 @@ async def create_support_ticket(
2929

3030
return (
3131
f"Support ticket created successfully.\n"
32-
f"*Ticket ID:* {ticket_id}\n"
33-
f"*Title:* {title}\n"
34-
f"*Priority:* {priority}\n"
35-
f"*Category:* {category}\n"
36-
f"*Status:* Open\n"
37-
f"*Assigned to:* IT Support Queue\n\n"
32+
f"**Ticket ID:** {ticket_id}\n"
33+
f"**Title:** {title}\n"
34+
f"**Priority:** {priority}\n"
35+
f"**Category:** {category}\n"
36+
f"**Status:** Open\n"
37+
f"**Assigned to:** IT Support Queue\n\n"
3838
f"The IT team will review this ticket and follow up within the SLA for {priority} priority issues."
3939
)

openai-agents-sdk/agent/tools/user_permissions.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -18,12 +18,12 @@ async def lookup_user_permissions(
1818
system: The system or resource to check permissions for (e.g., 'github', 'jira', 'aws').
1919
"""
2020
return (
21-
f"*Permissions for {target_user} on {system}:*\n\n"
22-
f"*Groups:* `{system}-users`, `{system}-readonly`\n"
23-
f"*Access Level:* Standard User\n"
24-
f"*Last Login:* 2 hours ago\n"
25-
f"*Account Status:* Active\n"
26-
f"*MFA Enabled:* Yes\n\n"
21+
f"**Permissions for {target_user} on {system}:**\n\n"
22+
f"**Groups:** `{system}-users`, `{system}-readonly`\n"
23+
f"**Access Level:** Standard User\n"
24+
f"**Last Login:** 2 hours ago\n"
25+
f"**Account Status:** Active\n"
26+
f"**MFA Enabled:** Yes\n\n"
2727
f"_To request elevated access, the user's manager must submit an access request "
2828
f"through the IT portal._"
2929
)

openai-agents-sdk/listeners/events/app_mentioned.py

Lines changed: 16 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,20 @@ def handle_app_mentioned(client: WebClient, event: dict, logger: Logger, say: Sa
4040
)
4141
return
4242

43+
# Set assistant thread status with loading messages
44+
client.assistant_threads_setStatus(
45+
channel_id=channel_id,
46+
thread_ts=thread_ts,
47+
status="Thinking...",
48+
loading_messages=[
49+
"Teaching the hamsters to type faster…",
50+
"Untangling the internet cables…",
51+
"Consulting the office goldfish…",
52+
"Polishing up the response just for you…",
53+
"Convincing the AI to stop overthinking…",
54+
],
55+
)
56+
4357
# Add eyes reaction
4458
client.reactions_add(
4559
channel=channel_id,
@@ -69,11 +83,8 @@ def handle_app_mentioned(client: WebClient, event: dict, logger: Logger, say: Sa
6983
feedback_blocks = create_feedback_block()
7084
response_blocks = [
7185
{
72-
"type": "section",
73-
"text": {
74-
"type": "mrkdwn",
75-
"text": result.final_output,
76-
},
86+
"type": "markdown",
87+
"text": result.final_output,
7788
},
7889
*feedback_blocks,
7990
]

0 commit comments

Comments
 (0)