$50 free credit for new accounts - ends in

Claim $50

Setup

How to set up knowledge base for hospital department dire…

How to set up knowledge base for hospital department directory chat — answered from your own docs. How Hospitals & Medical Centers teams use Chatref (knowledge

Chatref Team5 min read / Updated June 15, 2026

To set up a hospital department directory chat, add your department names, locations, hours, and contact information to Chatref as a knowledge base. Chatref trains an agent that answers visitor questions from that directory, and you embed the widget on your site so patients find the right department anytime. For more on Hospitals & Medical Centers, see Hospitals & Medical Centers.

Before you start

You need two things before you begin:

  • A compiled department directory. Gather the current list of departments, their full names, locations (floor, wing, building), hours of operation, phone extensions, and any other details patients commonly ask about. The cleaner the information, the better the agent will perform. You can prepare this as a PDF, a set of plain-text notes, or a page on your hospital website that lists all departments.

  • A Chatref account. Sign up at chatref.ai. Every new account includes free usage credit so you can test the directory agent before going live.

Chatref accepts PDFs, public URLs, sitemaps, and plain text as knowledge sources. If your directory is already published as a web page with clear headings and consistent structure, pointing the agent to that URL often gives the fastest results.

Step-by-step setup

  1. Create a new agent
    From the Chatref dashboard, click New Agent. Give it a name that patients will recognize, such as “Memorial Hospital Department Finder.” Choose a tone that matches your patient-facing communication — professional, warm, and direct. You can customize the agent’s primary color later to match your brand.

  2. Add your department directory
    In the agent’s Knowledge tab, choose your source type:

    • Upload a file if you have a clean PDF or text file listing every department.
    • Paste a URL if your directory exists on a public page. Chatref will crawl the page and read department blocks, headers, and contact blocks.
    • Paste plain text if you prefer to type or copy a structured list directly.

    For the most reliable results, use plain text with a consistent format. For example:

    Cardiology - Floor 2, West Wing. Hours: Mon-Fri 8am-5pm. Phone: 555-0123.
    Laboratory - Floor 1, East Wing. Hours: Daily 6am-8pm. Phone: 555-0145.
    

    Avoid complex tables or scanned PDFs that mix images and text; the agent retrieves information better from clean textual descriptions.

  3. Wait for processing
    Chatref reads your content in minutes. You can watch the status in the Knowledge tab. Once processing completes, the agent understands your department directory and will answer from it.

  4. Configure the widget appearance (optional)
    In the Widget settings, choose the accent color and decide the position on your site (bottom-right, corner, etc.). You can also set a welcome message like “Ask me where any department is or when it’s open.”

  5. Embed the widget on your hospital website
    Copy the provided JavaScript snippet. Paste it just before the closing </body> tag on every page where you want the chat to appear — typically the homepage, “Contact Us,” and patient information pages. Chatref verifies that requests come from your allowed domains automatically.

  6. Optionally, test in the playground
    Before going live, use the Playground tab to send test messages like “Where is radiology?” or “Is the pharmacy open on Sunday?”. Adjust your directory text if any answer misses a detail.

Check it works

Once the widget is live, verify with common patient questions:

  • Department location: “Where is the emergency department?” should return a clear location with building or wing.
  • Hours: “What time does the lab open on weekdays?” should pull the exact schedule from your directory.
  • Partial names: “Cardio” should still resolve to Cardiology if the directory is written clearly.
  • Multiple departments: “Laboratory and radiology hours” should handle each separately or note differences.

Test after every directory update (new hours, renamed department). If a question goes unanswered, check that the directory includes the exact phrasing a patient would use. Adding a short “Common Questions” source with phrasing variations often closes gaps.

Common issues

  • Directory is out of date. The agent can only answer from what it was given. If hours change or a department moves, update the source and reprocess. Keeping a plain-text file that you update regularly makes maintenance trivial.

  • PDFs with complex formatting. Scanned documents, multi-column layouts, and image-heavy PDFs can cause the agent to miss information. Convert a problematic PDF to plain text or publish the directory as a simple web page and point Chatref to the URL instead.

  • Ambiguous department names. If you have both “Radiology” and “Interventional Radiology,” the agent may confuse them. Always include full, unique names and clarify in the directory description (“Radiology (Diagnostic Imaging)” vs. “Interventional Radiology”).

  • Widget doesn’t appear. Check that the script snippet is pasted on the page and that your domain is allowed. If you use a tag manager or cookie consent tool, ensure the Chatref script isn’t blocked. The widget won’t load on localhost unless you whitelist the domain.

  • Patients ask about services not in the directory. The agent won’t guess outside its knowledge. Consider adding a short “Services by Department” source that maps common inquiries (“Where do I get an MRI?”) to the relevant department.

FAQ

What causes hospital department directory chat problems for Hospitals & Medical Centers?

Problems stem from an incomplete or outdated directory that leaves the agent without the information to answer a question. Complex PDF formatting, multiple departments with similar names, and missing synonyms for patient phrasing also lead to wrong or empty responses. The chat works only as well as the underlying directory data.

How do I improve hospital department directory chat for Hospitals & Medical Centers?

Maintain a single, up-to-date plain-text directory as the main knowledge source, and supplement it with a short FAQ document covering the phrasing patients actually use (e.g., “blood work” for laboratory). After every directory change, test the live widget with real patient questions and add any missing variations. Keeping the source clean and easy to read for the agent removes most accuracy problems.

Put this into practice

Chatref answers your customers from your own content, day and night. Add it to your site and go live in minutes – free to start.

Get started