SocialBuddy: Tailoring Search Agent for Social Scenarios
Organizations: WeChat, Tencent Inc, China · School of Information and Electronics, Beijing Institute of Technology, China · School of Computer Science and Technology, University of Science and Technology of China, China
Abstract
In the era of digital social interaction, searching friends' posts from massive social streams has become a fundamental user need. However, while modern agentic search frameworks have achieved remarkable success in conventional retrieval tasks, they break down when confronted with heterogeneous user queries and multi-dimensional social feeds, resulting in severe performance degradation in complex social search. To bridge this gap, we introduce SocialBuddy, the first agentic search framework tailored for social scenarios. Specifically, we construct SocialEnv, the first large-scale simulated environment for social search. Powered by an automated data and trajectory synthesis pipeline, SocialEnv includes 200K user profiles, 10 million social posts, and 50K reasoning trajectories, establishing a solid foundation for the development of social search agents. To tackle the credit assignment dilemma caused by sparse rewards in social search, we design SocialPO, a hybrid-granularity optimization framework. It macroscopically reinforces successful reasoning paths via multi-dimensional rewards, while microscopically rectifying deviated trajectories through fine-grained prefix truncation and token-level supervision. This hybrid-granularity design delivers multi-scale guidance in complex long-sequence scenarios. Finally, we construct SocialSearch Benchmark to provide a quantitative evaluation scheme for assessing the social search capabilities of SocialBuddy. Extensive experiments demonstrate that SocialBuddy-35B surpasses significantly larger frontier LLMs. Code and dataset will be released upon article acceptance.
Figures & tables
| Type | Model | Size | Easy Set | Hard Set | Avg. Overall | ||||||||
| SR | Prec. | Recall | EM | SR | Prec. | Recall | EM | Prec. | Recall | EM | |||
| API-based | Claude-4.5-Sonnet | N/A | 0.999 | 0.841 | 0.835 | 0.809 | 0.999 | 0.810 | 0.812 | 0.766 | 0.826 | 0.824 | 0.788 |
| Gemini-2.5-Flash | N/A | 0.913 | 0.732 | 0.747 | 0.684 | 0.868 | 0.635 | 0.627 | 0.609 | 0.684 | 0.687 | 0.647 | |
| Qwen3.5-Plus | N/A | 0.997 | 0.904 | 0.891 | 0.834 | 0.993 | 0.881 | 0.874 | 0.853 | 0.893 | 0.883 | 0.844 | |
| GPT-5 | N/A | 0.998 | 0.912 | 0.921 | 0.892 | 0.995 | 0.884 | 0.887 | 0.848 | 0.898 | 0.904 | 0.870 | |
| Open-weights | DeepSeek-V4-Flash | 284B | 0.999 | 0.820 | 0.819 | 0.786 | 0.985 | 0.729 | 0.714 | 0.687 | 0.775 | 0.767 | 0.737 |
| Method / Variant | Prec. | Recall | EM |
|---|---|---|---|
| Qwen3.5-9B (Base) | 0.783 | 0.778 | 0.732 |
| + SFT | 0.865 | 0.868 | 0.835 |
| + OPD | 0.921 | 0.924 | 0.909 |
| + RL (w/ F1-Score Reward only) | 0.892 | 0.905 | 0.878 |
| + RL (w/ Macro Composite Reward) | 0.914 | 0.921 | 0.894 |
| + RL (w/ Macro Reward+OPD) | 0.941 | 0.943 | 0.921 |
| Model | HR (%) | Top-1 (%) | Top-2 (%) |
|---|---|---|---|
| Qwen3.5-35B-A3B | 1.6 | 8.3 | 23.8 |
| GLM-5.2 | 0.8 | 13.1 | 38.2 |
| Qwen3.5-397B-A17B | 1.3 | 21.4 | 46.5 |
| SocialBuddy-35B (Ours) | 1.4 | 64.2 | 91.5 |
| Tool | Operator | Parameters | Responsibility and evidence boundary |
|---|---|---|---|
| select_by_person | name ; relationship_type ; closeness ; gender ; age_group | Conjunctively filters identity, authorized social-graph attributes, and demographic cohorts. It does not infer authorship from post content or residence. | |
| select_by_time | start_date ; end_date ; weekday ; festival ; time_of_day | Grounds absolute, periodic, and event-driven constraints in publication metadata rather than textual mentions; date bounds are inclusive. | |
| select_by_location | keyword | Restricts spatial provenance to normalized poi_city or poi_name evidence attached to a post, explicitly excluding author residence. | |
| select_by_content | post_type ; semantic_query | Applies an exact modality gate, then batched semantic assessment of principal-subject relevance over the survivors; private author fields and generated topics are withheld. | |
| finalize | sort_by | Orders only eligible candidates by the requested objective and returns at most five sanitized records; it neither introduces a new relevance predicate nor re-filters the pool. |
| Argument | Type / status | Accepted input | Matching rule |
|---|---|---|---|
| Author metadata selection — select_by_person | |||
| name | string; optional | Free-form name or alias | Remove all whitespace and lowercase; retain an author when the query is a substring of either nickname or remark_name . |
| relationship_ type | enum; optional | self , family , relative , significant_other , colleague , college_classmate , school_classmate , friend , online_friend , acquaintance , neighbor , business_partner | Case-normalized exact match on the stored relationship category. |
| closeness | enum; optional | close , normal , distant , self | Case-normalized exact match on tie strength. |
| gender | enum; optional | male , female | Case-normalized exact match on profile metadata. |
| age_group | enum; optional | child , young , middle , senior | Maps respectively to stored categories child ; adolescent / young_adult ; adult / middle_aged ; and senior . Public interpretations are 7–12, 13–29, 30–65, and 66+. |
| Argument | Type / status | Accepted input | Matching rule |
|---|---|---|---|
| Publication-time selection — select_by_time | |||
| start_date | string; optional | YYYY-MM-DD | Inclusive lower calendar-date bound on post_time . |
| end_date | string; optional | YYYY-MM-DD | Inclusive upper calendar-date bound on post_time . |
| weekday | string; optional | Full name/abbreviation; 0 – 6 (Monday= 0 ); weekday ; weekend | Normalize to English weekday names and exactly match the recorded weekday field. |
| festival | enum; optional | One canonical festival label | Intersect with the recorded festival list. Spring Festival additionally includes its first-, second-, and third-day labels; no post-text inference is used. |
| time_of_day | enum; optional | morning , noon , afternoon , evening , night , midnight | Match half-open hour buckets , , , , , and , respectively. |
| Tool / argument | Type / status | Accepted input | Implementation and output |
| Spatial selection — select_by_location | |||
| keyword | string; required | City or POI phrase | Normalize case, apostrophes, and common trailing administrative suffixes; substring-match poi_city or poi_name . Update pool membership and report before/after counts. |
| Hybrid content selection — select_by_content | |||
| post_type | enum; optional | image , text , video , share_music , share_article | Apply an exact, in-memory modality gate before semantic inference. |
| semantic_query | string; optional | Open-vocabulary natural-language criterion | Select principal-subject matches from numbered post summaries, at most 100 per batch. Author fields, identifiers, raw time, weekday, and generated topics are withheld. |
| Terminal presentation — finalize | |||
| Role | Content |
|---|---|
| User | Query: show me HongJunYan’s text-only posts about reflecting on farming from Burqin in the evening over the last 30 days, sorted by most likes Reference time: Monday, September 8, 2025, 02:23. |
| Agent Step 1 | The query names HongJunYan, so I begin with the person filter. select_by_person(name="HongJunYan") |
| Observation | 2,041 23. The normalized name matched remark_name=HongJunYan . |
| Agent Step 2 | Resolve “last 30 days” to August 10 through September 8 and retain evening posts. select_by_time(start_date="2025-08-10", end_date="2025-09-08", time_of_day="evening") |
| Observation | 23 4. Matched the inclusive date range and evening bucket. |
| Agent Step 3 | Enforce the explicit Burqin provenance before inspecting content. select_by_location(keyword="Burqin") |
| Role | Content |
|---|---|
| User | Query: show me the video from friends last week late at night tagged in Weifang about showing off denim jackets with the most likes Reference time: Friday, July 4, 2025, 12:27. |
| Agent Step 1 | Restrict the pool to posts from friends. select_by_person(relationship_type="friend") |
| Observation | 1,030 251. Relationship metadata matched. |
| Agent Step 2 | Resolve last week to June 23–29 and map late night to midnight. select_by_time(start_date="2025-06-23", end_date="2025-06-29", time_of_day="midnight") |
| Observation | 251 11. The date range and midnight bucket matched. |
| Agent Step 3 | Apply the Weifang provenance constraint. select_by_location(keyword="Weifang") |
| Role | Content |
|---|---|
| User | Query: Find my posts from Spring Festival about grandpa saying goodnight at Gongheyong with the most comments. Reference time: Wednesday, March 4, 2026, 04:33. |
| Agent Step 1 | “My posts” maps to self-authorship. select_by_person(relationship_type="self") |
| Observation | 8,663 23. The self relationship matched. |
| Agent Step 2 | Use the canonical Spring Festival annotation rather than a guessed date range. select_by_time(festival="Spring Festival") |
| Observation | 23 2. Spring Festival and its first three day labels were included. |
| Agent Step 3 | Apply the Gongheyong POI constraint. select_by_location(keyword="Gongheyong") |
| Role | Content |
|---|---|
| User | Query: posts by ShiRongPo about morning walk to school in Qingdao in the morning with the most comments Reference time: Wednesday, March 11, 2026, 03:54. |
| Agent Step 1 | The query names ShiRongPo. select_by_person(name="ShiRongPo") |
| Observation | 7,003 52. The normalized name matched remark_name=ShiRongPo . |
| Agent Step 2 | The publication-time constraint is morning. select_by_time(time_of_day="morning") |
| Observation | 52 14. Morning posts were retained. |
| Agent Step 3 | Apply the Qingdao provenance constraint. select_by_location(keyword="Qingdao") |
| Role | Content |
|---|---|
| User | Query: friends posts about recording sunset over Kaiyuan on Saturday evening Reference time: Wednesday, April 22, 2026, 10:06. |
| Agent Step 1 | Restrict the pool to posts from friends. select_by_person(relationship_type="friend") |
| Observation | 6,829 2,444. Relationship metadata matched. |
| Agent Step 2 | Retain posts published on Saturday evenings. select_by_time(weekday="Saturday", time_of_day="evening") |
| Observation | 2,444 58. Weekday and evening predicates matched. |
| Agent Step 3 | Interpret Kaiyuan as an explicit post-location constraint. select_by_location(keyword="Kaiyuan") |
| Role | Content |
|---|---|
| User | Query: show posts about a child saying goodnight tagged at Kashgar posted late at night with the most likes Reference time: Thursday, October 23, 2025, 08:38. |
| Agent Step 1 | Interpret “a child” as an author-age constraint. select_by_person(age_group="child") |
| Observation | 5,681 357. Child author profiles were retained. |
| Agent Step 2 | Map late night to the midnight bucket. select_by_time(time_of_day="midnight") |
| Observation | 357 56. Midnight posts were retained. |
| Agent Step 3 | Apply the Kashgar location tag. select_by_location(keyword="Kashgar") |
| Facet | Source field(s) | Instantiated value |
|---|---|---|
| Demographic and setting | ||
| Identity | age_info , gender | 34-year-old adult woman. |
| Location | location | Rural Guizhou, China; the source places her in the Qiandongnan Miao and Dong Autonomous Prefecture. |
| Education | education | Ph.D.; key-university background. |
| Household and work | ||
| Family | family | Married; lives with her spouse, two children, and father-in-law in a rural multigenerational household. |
| Facet | Source field(s) | Instantiated value |
|---|---|---|
| Demographic and setting | ||
| Identity | age_info , gender | 81-year-old senior woman. |
| Location | location | Chongqing, China. |
| Education | education | Bachelor’s education; public-school background. |
| Household and work | ||
| Family | family | Widowed; two children; lives with her son’s family, including an adult grandson, in a multigenerational household. |
| Facet | Source field(s) | Instantiated value |
|---|---|---|
| Demographic and setting | ||
| Identity | age_info , gender | 54-year-old middle-aged woman. |
| Location | location | Weifang, Shandong, China. |
| Education | education | College education; public-school background. |
| Household and work | ||
| Family | family | Married; lives with her spouse, adult son, and young granddaughter in a multigenerational household. |
| Facet | Source field(s) | Instantiated value |
|---|---|---|
| Demographic and setting | ||
| Identity | age_info , gender | 51-year-old middle-aged woman. |
| Location | location | Chongqing, China. |
| Education | education | Bachelor’s education; private-school background. |
| Household and work | ||
| Family | family | Married; lives with her spouse, adult daughter, and elderly mother in a multigenerational urban household. |
| Facet | Source field(s) | Instantiated value |
|---|---|---|
| Demographic and setting | ||
| Identity | age_info , gender | 32-year-old adult woman. |
| Location | location | Coastal Guangdong, China. |
| Education | education | College education; private-school background. |
| Household and work | ||
| Family | family | Married; lives with her spouse, young daughter, and mother-in-law in a multigenerational urban household. |
| Field group | Included attributes | Role in synthesis | Exposure to social search |
|---|---|---|---|
| Public author layer | |||
| Author attributes | Age or age group, gender, surface identity, relationship type, and closeness. | Conditions author identity and voice. | Authorized categorical subset consumed by select_by_person . |
| Private generation context | |||
| Background context | Education, occupation, coarse home region, household composition, housing, and mobility. | Establishes persistent lived context. | Not directly exposed. |
| Behavioral context | Daily routine, values, life attitude, coping mechanism, interests, and narrative anchors. | Governs recurring activities, concerns, and interpretations. | Not directly exposed. |
| Expression controls | Screen name, posting archetype, tone, frequency, common-topic priors, and style description. | Regulates topic sampling and linguistic realization. | Not directly exposed as selector predicates. |
| Type / ID | Time, context, engagement | Authored text and payload | Persona realization |
|---|---|---|---|
| A1 — Gardening milestone | |||
| text 005 | 2025-08-04 15:48:47 Monday; festival: none Topic: gardening POI: none 30 likes; 7 comments | Post: “The first tomato finally ripened on the vine this afternoon. A small, red milestone after months of tending.” Payload: Media/share: none. | Gardening is explicit; the measured “milestone” and restrained two-sentence caption instantiate patient maintenance and steady progress. |
| A2 — Rural commute pause | |||
| image 012 | 2025-08-27 17:23:00 Wednesday; festival: none Topic: cloud notes POI city: Long’e County POI name: withheld 40 likes; 5 comments | Post: “5:23 PM. The clouds over Long’e are putting on a show again. Just stopped the e-bike to look up before heading home to the kids.” Payload: 9 images; video count: none. Descriptions cover sunset clouds, an e-bike on a rural road, weather display, karst mountains, a wedding band, power lines, a puddle reflection, cloud detail, and fields at the horizon. | The rural commute, e-bike, return to her children, and deliberate pause jointly expose daily routine and the stated reflective coping pattern. |
| A3 — Dawn household routine | |||
| video 010 | 2025-08-16 05:30:55 Saturday; festival: none Topic: home cooking POI: none 12 likes; 0 comments | Post: “5:30 AM. The kitchen is quiet while everyone sleeps. Starting the congee before the morning rush begins.” Payload: Image count: none; 1 video describing rice congee simmering on a gas stove in a dim kitchen, with steam rising from the pot. | Early meal preparation materializes planning and care for a multigenerational household; the precise timestamp and wording remain methodical. |
| Type / ID | Time, context, engagement | Authored text and payload | Persona realization |
|---|---|---|---|
| B1 — Traditional family lunch | |||
| text 012 | 2025-09-29 12:21:45 Monday; festival: none Topic: Cooking traditional Chinese cuisine POI: none 44 likes; 2 comments | Post: “Lunch is ready: braised pork and steamed fish. The grandson loved it. A quiet Monday at home.” Payload: Media/share: none. | Traditional cooking and care for her adult grandson appear in a concise domestic update consistent with a gentle Family Elder voice. |
| B2 — Reciprocal digital learning | |||
| image 042 | 2026-05-08 17:12:36 Friday; festival: none Topic: iPad POI: none 26 likes; 7 comments | Post: “Late afternoon light filters through the window, warming the screen where my grandson teaches me to paint. Time slows down in these quiet, colorful moments.” Payload: 9 images; video count: none. Descriptions show a tablet, stylus and watercolor interface, an elderly learner and younger guide, plum-blossom painting, tea, warm window light, a sketch gallery, and the pair seated together. | Reciprocal learning reverses the usual direction of care while preserving intergenerational continuity and openness to new practices. |
| B3 — Tai Chi routine | |||
| video 002 | 2025-07-04 19:08:25 Friday; festival: none Topic: Tai Chi POI: none 30 likes; 8 comments | Post: “Even at 81, my Tai Chi flows strong in the summer evening breeze! So proud of keeping active for my family.” Payload: Image count: none; 1 video describing an elderly woman performing slow Tai Chi movements in a community park at dusk. | Age, established exercise routine, community setting, and family-oriented motivation are simultaneously observable. |
| Type / ID | Time, context, engagement | Authored text and payload | Persona realization |
|---|---|---|---|
| C1 — Work–family continuity | |||
| text 021 | 2025-12-16 14:12:57 Tuesday; festival: none Topic: seasonal greetings POI city: Weifang POI name: media workplace (coarsened) 31 likes; 10 comments | Post: “Just finished a quick lunch at the office. The winter sun is weak today, but seeing my granddaughter’s drawing of snowflakes on my desk warms my heart. Can’t wait to pick her up and make hot pear soup for everyone tonight. Winter in Mihe is cold, but our home is cozy.” Payload: Media/share: none. | Office work, kindergarten pickup, family cooking, season, and a warm domestic register are integrated in one record. |
| C2 — Intergenerational overnight care | |||
| image 003 | 2025-06-06 03:14:46 Friday; festival: none Topic: diary POI: none 22 likes; 3 comments | Post: “3:14 AM and the house is finally quiet. My granddaughter had a fever tonight, so her mom and I took turns watching her. She’s sleeping soundly now. I’ll brew some ginger tea for myself before heading back to bed. These late nights remind me how fast time flies; my son was once the one I stayed up with, and now I’m doing it for his little girl. Summer nights are warm, but the worry keeps you alert. Goodnight, world.” Payload: 1 image; video count: none. The description shows a dim living room, amber tea, a digital clock reading 03:14, and a summer blanket. | Overnight care links past parenting to present grandparenting and makes multigenerational cooperation observable. |
| C3 — Professional reflection | |||
| video 006 | 2025-07-08 01:59:29 Tuesday; festival: none Topic: work POI: none 0 likes; 0 comments | Post: “It’s late, but the office is finally quiet. After decades in media, I’ve learned that the best decisions often come not in the rush of the day, but in these still moments. Watching the city sleep from my window, everything feels clear and in its place.” Payload: Image count: none; 1 video describing a dim office, desk lamp, papers, dark monitor, rain-streaked window, and city lights. | “Decades in media” grounds the occupation, while deliberate judgment and quiet reflection align with steady, responsible leadership. |