Designing an mcp server
Identifying Tools
- Mental Model
What actions do we expect ai to perform on behalf of some user or role.
It should not be everything or too much specific
Identify roles/user types
Identifying Resources
- Mental Model
What data would ai need
Identifying Prompts
- Mental Model
What are most obvious things which ai is going to ask
Problem: MCP Server for College Library
-
Users:
- Librarians
- Students
-
Think of librarian activities
Pending returns
issue books
process return books
fine management
add books
retiring books
quarterly summary
fines
return and issue summary
account_balance
no dues certificates
article subscriptions
book catalog
manage reservations
rack management
process damage
process lost books
Track returns and send remainders
- Student
search book
issue
return
pay fine
collect no dues
reserve a book
extend
- Questions
Top performing books
Low Performing books
Account summary
Shortage books
possible future orders
- Tools: What we want AI to do (actions)
issue_book(student_id, book_id, date)
process_return(student_id, book_id, date, description) -> float:
add_book(book_id, description):
update_policy(policy_id, new_policy)
notify_student_about_reservation(student_id, book_id, reason)
hold_book(book_id)
deactivate_student(student_id)
notify(student_id, message)
issue_no_due_certificate(student_id)
collect_fine(student_id, amount)
create_account_statement(from, to)
collect_book
return_book
pay_fine
reserve_book
extend_book
request_no_dues
- Resources: Data that AI might need to read
book_info_by_id
get_book_id
get_book_rack
get_availability_by_id
get_reservation_details_for_book
# individual
get_fine_due
total_account_balance
- Prompts
Returns_due_today
Monthly summary of fine collection
Monthly summary of book ledger
Top Performing books
Under Performing books
- Exercise:
Do the similar stuff for an mcp server for
irctc for a customer
