From c503ad5d0f36aefac39a46fae7d7f9a64cf502eb Mon Sep 17 00:00:00 2001 From: Tyrin Todd Date: Sat, 25 Apr 2026 21:29:55 -0700 Subject: [PATCH] server-inference push dbpedia_hard --- README.md | 3 + config.json | 356 +++++++++++++++++++++++++++++++++++++++++++++++++++ program.json | 48 +++++++ 3 files changed, 407 insertions(+) create mode 100644 config.json create mode 100644 program.json diff --git a/README.md b/README.md index e69de29..1388a48 100644 --- a/README.md +++ b/README.md @@ -0,0 +1,3 @@ +--- +{} +--- \ No newline at end of file diff --git a/config.json b/config.json new file mode 100644 index 0000000..0e31c5e --- /dev/null +++ b/config.json @@ -0,0 +1,356 @@ +{ + "model": null, + "signature": { + "description": "Classify the Wikipedia article excerpt into all three levels of the DBpedia ontology hierarchy: L1 (9 classes), L2 (70 classes), and L3 (219 classes).\nAs you reason, note any uncertainties, ambiguities, and gaps \u2014 both in how the instructions apply to the task at hand and in whether you have the knowledge needed to solve it. Be honest in your reasoning when you are unsure about your answer.", + "properties": { + "text": { + "__dspy_field_type": "input", + "desc": "Wikipedia article excerpt to classify.", + "prefix": "Text:", + "title": "Text", + "type": "string" + }, + "reasoning": { + "__dspy_field_type": "output", + "desc": "Step-by-step reasoning, including uncertainty, ambiguity, or uncertainty in your thought process when relevant.", + "prefix": "Reasoning:", + "title": "Reasoning", + "type": "string" + }, + "l1_class": { + "__dspy_field_type": "output", + "desc": "Top-level DBpedia ontology category. One of: Agent, Device, Event, Place, Species, SportsSeason, TopicalConcept, UnitOfWork, Work.", + "enum": [ + "Agent", + "Device", + "Event", + "Place", + "Species", + "SportsSeason", + "TopicalConcept", + "UnitOfWork", + "Work" + ], + "prefix": "L 1 Class:", + "title": "L1 Class", + "type": "string" + }, + "l2_class": { + "__dspy_field_type": "output", + "desc": "Second-level DBpedia ontology subcategory (must be a valid subcategory of the chosen L1).", + "enum": [ + "Actor", + "AmusementParkAttraction", + "Animal", + "Artist", + "Athlete", + "BodyOfWater", + "Boxer", + "BritishRoyalty", + "Broadcaster", + "Building", + "Cartoon", + "CelestialBody", + "Cleric", + "ClericalAdministrativeRegion", + "Coach", + "Comic", + "ComicsCharacter", + "Company", + "Database", + "EducationalInstitution", + "Engine", + "Eukaryote", + "FictionalCharacter", + "FloweringPlant", + "FootballLeagueSeason", + "Genre", + "GridironFootballPlayer", + "Group", + "Horse", + "Infrastructure", + "LegalCase", + "MotorcycleRider", + "MusicalArtist", + "MusicalWork", + "NaturalEvent", + "NaturalPlace", + "Olympics", + "Organisation", + "OrganisationMember", + "PeriodicalLiterature", + "Person", + "Plant", + "Politician", + "Presenter", + "Race", + "RaceTrack", + "RacingDriver", + "RouteOfTransportation", + "Satellite", + "Scientist", + "Settlement", + "SocietalEvent", + "Software", + "Song", + "SportFacility", + "SportsEvent", + "SportsLeague", + "SportsManager", + "SportsTeam", + "SportsTeamSeason", + "Station", + "Stream", + "Tournament", + "Tower", + "Venue", + "VolleyballPlayer", + "WinterSportPlayer", + "Wrestler", + "Writer", + "WrittenWork" + ], + "prefix": "L 2 Class:", + "title": "L2 Class", + "type": "string" + }, + "l3_class": { + "__dspy_field_type": "output", + "desc": "Third-level DBpedia ontology subcategory (must be a valid subcategory of the chosen L2).", + "enum": [ + "AcademicJournal", + "AdultActor", + "Airline", + "Airport", + "Album", + "AmateurBoxer", + "Ambassador", + "AmericanFootballPlayer", + "Amphibian", + "AnimangaCharacter", + "Anime", + "Arachnid", + "Architect", + "ArtificialSatellite", + "ArtistDiscography", + "Astronaut", + "AustralianFootballTeam", + "AustralianRulesFootballPlayer", + "AutomobileEngine", + "BadmintonPlayer", + "Band", + "Bank", + "Baronet", + "BaseballLeague", + "BaseballPlayer", + "BaseballSeason", + "BasketballLeague", + "BasketballPlayer", + "BasketballTeam", + "BeachVolleyballPlayer", + "BeautyQueen", + "BiologicalDatabase", + "Bird", + "Bodybuilder", + "Brewery", + "Bridge", + "BroadcastNetwork", + "BusCompany", + "BusinessPerson", + "CanadianFootballTeam", + "Canal", + "Canoeist", + "Cardinal", + "Castle", + "Cave", + "Chef", + "ChessPlayer", + "ChristianBishop", + "ClassicalMusicArtist", + "ClassicalMusicComposition", + "CollegeCoach", + "Comedian", + "ComicStrip", + "ComicsCreator", + "Congressman", + "Conifer", + "Convention", + "CricketGround", + "CricketTeam", + "Cricketer", + "Crustacean", + "CultivatedVariety", + "Curler", + "Cycad", + "CyclingRace", + "CyclingTeam", + "Cyclist", + "Dam", + "DartsPlayer", + "Diocese", + "Earthquake", + "Economist", + "Election", + "Engineer", + "Entomologist", + "EurovisionSongContestEntry", + "FashionDesigner", + "Fern", + "FigureSkater", + "FilmFestival", + "Fish", + "FootballMatch", + "FormulaOneRacer", + "Fungus", + "GaelicGamesPlayer", + "Galaxy", + "Glacier", + "GolfCourse", + "GolfPlayer", + "GolfTournament", + "Governor", + "GrandPrix", + "Grape", + "GreenAlga", + "Gymnast", + "HandballPlayer", + "HandballTeam", + "Historian", + "HistoricBuilding", + "HockeyTeam", + "HollywoodCartoon", + "HorseRace", + "HorseRider", + "HorseTrainer", + "Hospital", + "Hotel", + "IceHockeyLeague", + "IceHockeyPlayer", + "Insect", + "Jockey", + "Journalist", + "Judge", + "LacrossePlayer", + "Lake", + "LawFirm", + "Legislature", + "Library", + "Lighthouse", + "Magazine", + "Manga", + "MartialArtist", + "Mayor", + "Medician", + "MemberOfParliament", + "MilitaryConflict", + "MilitaryPerson", + "MilitaryUnit", + "MixedMartialArtsEvent", + "Model", + "Mollusca", + "Monarch", + "Moss", + "Mountain", + "MountainPass", + "MountainRange", + "Museum", + "MusicFestival", + "MusicGenre", + "Musical", + "MythologicalFigure", + "NCAATeamSeason", + "NascarDriver", + "NationalFootballLeagueSeason", + "NetballPlayer", + "Newspaper", + "Noble", + "OfficeHolder", + "OlympicEvent", + "Painter", + "Philosopher", + "Photographer", + "Planet", + "Play", + "PlayboyPlaymate", + "Poem", + "Poet", + "PokerPlayer", + "PoliticalParty", + "Pope", + "President", + "PrimeMinister", + "Prison", + "PublicTransitSystem", + "Publisher", + "RaceHorse", + "Racecourse", + "RadioHost", + "RadioStation", + "RailwayLine", + "RailwayStation", + "RecordLabel", + "Religious", + "Reptile", + "Restaurant", + "River", + "Road", + "RoadTunnel", + "RollerCoaster", + "Rower", + "RugbyClub", + "RugbyLeague", + "RugbyPlayer", + "Saint", + "School", + "ScreenWriter", + "Senator", + "ShoppingMall", + "Single", + "Skater", + "Skier", + "SoapCharacter", + "SoccerClubSeason", + "SoccerLeague", + "SoccerManager", + "SoccerPlayer", + "SoccerTournament", + "SolarEclipse", + "SpeedwayRider", + "SportsTeamMember", + "SquashPlayer", + "Stadium", + "SumoWrestler", + "SupremeCourtOfTheUnitedStatesCase", + "Swimmer", + "TableTennisPlayer", + "TelevisionStation", + "TennisPlayer", + "TennisTournament", + "Theatre", + "Town", + "TradeUnion", + "University", + "VideoGame", + "Village", + "VoiceActor", + "Volcano", + "Winery", + "WomensTennisAssociationTournament", + "WrestlingEvent" + ], + "prefix": "L 3 Class:", + "title": "L3 Class", + "type": "string" + } + }, + "required": [ + "text", + "reasoning", + "l1_class", + "l2_class", + "l3_class" + ], + "title": "DBPediaHardJudgeSig", + "type": "object" + } +} \ No newline at end of file diff --git a/program.json b/program.json new file mode 100644 index 0000000..6b45fa0 --- /dev/null +++ b/program.json @@ -0,0 +1,48 @@ +{ + "traces": [], + "train": [], + "demos": [], + "signature": { + "instructions": "Classify the Wikipedia article excerpt into all three levels of the DBpedia ontology hierarchy: L1 (9 classes), L2 (70 classes), and L3 (219 classes).\nAs you reason, note any uncertainties, ambiguities, and gaps \u2014 both in how the instructions apply to the task at hand and in whether you have the knowledge needed to solve it. Be honest in your reasoning when you are unsure about your answer.", + "fields": [ + { + "prefix": "Text:", + "description": "Wikipedia article excerpt to classify." + }, + { + "prefix": "Reasoning:", + "description": "Step-by-step reasoning, including uncertainty, ambiguity, or uncertainty in your thought process when relevant." + }, + { + "prefix": "L 1 Class:", + "description": "Top-level DBpedia ontology category. One of: Agent, Device, Event, Place, Species, SportsSeason, TopicalConcept, UnitOfWork, Work." + }, + { + "prefix": "L 2 Class:", + "description": "Second-level DBpedia ontology subcategory (must be a valid subcategory of the chosen L1)." + }, + { + "prefix": "L 3 Class:", + "description": "Third-level DBpedia ontology subcategory (must be a valid subcategory of the chosen L2)." + } + ] + }, + "lm": { + "model": "together_ai/Qwen/Qwen2.5-7B-Instruct-Turbo", + "model_type": "chat", + "cache": true, + "num_retries": 3, + "finetuning_model": null, + "launch_kwargs": {}, + "train_kwargs": {}, + "temperature": null, + "max_tokens": null + }, + "metadata": { + "dependency_versions": { + "python": "3.11", + "dspy": "3.1.3", + "cloudpickle": "3.1" + } + } +} \ No newline at end of file