def METHOD_NAME(request):
    """
    Determine which top-level nav category a request falls under
    for the purposes of the left nav bar.
    """
    categories = [
        (r"^/$", "dashboard"),
        (r"^/announcements", "dashboard"),
        (r"^/eighth/admin", "eighth_admin"),
        (r"^/eighth", "eighth"),
        (r"^/schedule", "schedule"),
        (r"^/events", "events"),
        (r"^/enrichment", "enrichment"),
        (r"^/files", "files"),
        (r"^/printing", "printing"),
        (r"^/groups", "groups"),
        (r"^/polls", "polls"),
        (r"^/board", "board"),
        (r"/bus", "bus"),
    ]
    for pattern, category in categories:
        p = re.compile(pattern)
        if p.match(request.path):
            return {"nav_category": category}
    return {"nav_category": ""}