[go: up one dir, main page]

CN111984854A - Method and apparatus for presenting category information - Google Patents

Method and apparatus for presenting category information Download PDF

Info

Publication number
CN111984854A
CN111984854A CN201910434577.6A CN201910434577A CN111984854A CN 111984854 A CN111984854 A CN 111984854A CN 201910434577 A CN201910434577 A CN 201910434577A CN 111984854 A CN111984854 A CN 111984854A
Authority
CN
China
Prior art keywords
category
user
categories
sequence
candidate
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN201910434577.6A
Other languages
Chinese (zh)
Inventor
戴旭
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Jingdong Century Trading Co Ltd
Beijing Jingdong Shangke Information Technology Co Ltd
Original Assignee
Beijing Jingdong Century Trading Co Ltd
Beijing Jingdong Shangke Information Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing Jingdong Century Trading Co Ltd, Beijing Jingdong Shangke Information Technology Co Ltd filed Critical Beijing Jingdong Century Trading Co Ltd
Priority to CN201910434577.6A priority Critical patent/CN111984854A/en
Publication of CN111984854A publication Critical patent/CN111984854A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/90Details of database functions independent of the retrieved data types
    • G06F16/95Retrieval from the web
    • G06F16/953Querying, e.g. by the use of web search engines
    • G06F16/9535Search customisation based on user profiles and personalisation
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/90Details of database functions independent of the retrieved data types
    • G06F16/95Retrieval from the web
    • G06F16/953Querying, e.g. by the use of web search engines
    • G06F16/9538Presentation of query results

Landscapes

  • Engineering & Computer Science (AREA)
  • Databases & Information Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Data Mining & Analysis (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The embodiment of the application discloses a method and a device for presenting category information. One embodiment of the method comprises: sorting the categories in the category list according to the latest access time and access times of the user to the categories in the pre-created category list to generate a candidate category sequence; adjusting the ordering of the categories in the candidate category sequence according to the most recently accessed category of the user; and presenting the category information according to the adjusted category sequence. According to the method and the device, the categories are presented after being sorted according to the latest access categories of the users, so that the category information is presented differently for different users, the order of presenting the categories is more in line with the requirements of the users, and the efficiency of presenting the category information is improved.

Description

用于呈现类目信息的方法和装置Method and apparatus for presenting category information

技术领域technical field

本申请实施例涉及计算机技术领域,具体涉及网络技术领域,尤其涉及用于呈现类目信息的方法和装置。The embodiments of the present application relate to the field of computer technologies, in particular to the field of network technologies, and in particular, to a method and apparatus for presenting category information.

背景技术Background technique

随着互联网的发展和普及,人们使用网络进行浏览信息以及购物越来越普遍。目前,网络应用的分类类目排序的方法,通常是通过预先设定的类目排序呈现给用户。不同用户的喜好差异较大,存在针对单个用户进行个性化定制类目信息排序的需求。With the development and popularization of the Internet, it is more and more common for people to use the Internet to browse information and shop. At present, the method for sorting categories of network applications is usually presented to the user through a preset sorting of categories. The preferences of different users are quite different, and there is a need to customize the sorting of category information for a single user.

发明内容SUMMARY OF THE INVENTION

本申请实施例提出了用于呈现类目信息的方法和装置。The embodiments of the present application propose a method and apparatus for presenting category information.

第一方面,本公开的实施例提供了一种用于呈现类目信息的方法,包括:根据用户对预先创建的类目表中的类目的最近访问时间和访问次数,对上述类目表中的类目进行排序,生成候选类目序列;根据上述用户的最近访问类目调整上述候选类目序列中的类目的排序;按照调整后的类目的排序呈现类目信息。In a first aspect, an embodiment of the present disclosure provides a method for presenting category information, including: according to a user's recent access time and number of visits to a category in a pre-created category table, Sort the categories in the candidate category sequence to generate a candidate category sequence; adjust the ranking of the categories in the candidate category sequence according to the last visited category of the user; and present category information according to the adjusted category ranking.

在一些实施例中,上述根据用户对预先创建的类目表中的类目的最近访问时间和访问次数,对上述类目表中的类目进行排序,生成候选类目序列,包括:根据预设的最近访问时间权重和访问次数权重,对上述类目表中的类目的最近访问时间和访问次数加权求和,确定上述类目表中的类目的排序值;按照排序值由大到小对类目表中的类目进行排序,选择排序前预设位的类目生成候选类目序列。In some embodiments, the above-mentioned sorting the categories in the category table according to the latest access time and the number of visits of the categories in the pre-created category table by the user, and generating a sequence of candidate categories, including: according to the predetermined category table. Set the weight of the recent access time and the number of visits, weighted summation of the most recent access time and the number of visits of the categories in the above category table, and determine the sorting value of the categories in the above category table; Sort the categories in the category table, and select the categories preset before sorting to generate a candidate category sequence.

在一些实施例中,上述根据上述用户的最近访问类目调整上述候选类目序列中的类目的排序,包括:响应于确定上述用户的最近访问类目位于上述候选类目序列中,将上述用户的最近访问类目调整至上述候选类目序列的首位。In some embodiments, adjusting the ranking of the categories in the sequence of candidate categories according to the category recently visited by the user includes: in response to determining that the category recently visited by the user is in the sequence of candidate categories, placing the category in the sequence of candidate categories The user's recently visited category is adjusted to the top of the above candidate category sequence.

在一些实施例中,上述根据上述用户的最近访问类目调整上述候选类目序列中的类目的排序,还包括:响应于确定上述用户的最近访问类目不位于上述候选类目序列中,将上述用户的最近访问类目插入至上述候选类目序列的首位;响应于在首位插入上述用户的最近访问类目后的候选类目序列的长度超过上述候选类目序列的最大长度,将在首位插入上述用户的最近访问类目后的候选类目序列中排序末位的类目删除。In some embodiments, adjusting the ranking of the categories in the sequence of candidate categories according to the category recently visited by the user further includes: in response to determining that the category recently visited by the user is not located in the sequence of candidate categories, Insert the most recently visited category of the above-mentioned user into the first position of the above-mentioned candidate category sequence; in response to the length of the candidate category sequence after inserting the above-mentioned user's recently visited category at the first position exceeds the maximum length of the above-mentioned candidate category sequence, the The last category in the sequence of candidate categories after the first one is inserted into the most recently accessed category of the above-mentioned user is deleted.

在一些实施例中,上述方法应用于客户端。In some embodiments, the above-described method is applied to a client.

在一些实施例中,上述预先创建的类目表是通过以下创建步骤得到的:创建类目表,类目表中的每一条数据包括类目标识、访问次数、最近访问时间;确定用户访问的物品信息所属类目的类目标识,响应于确定上述类目表中存在用户访问的物品信息所属类目的类目标识,将上述类目表中上述用户访问的物品信息所属类目的类目标识对应的访问次数加一,将上述类目表中上述用户访问的物品信息所属类目的类目标识对应的最近访问时间更新为上述用户访问上述物品信息的时间。In some embodiments, the above-mentioned pre-created category table is obtained through the following creation steps: creating a category table, each piece of data in the category table includes category identification, number of visits, and recent visit time; The category identifier of the category to which the item information belongs, in response to determining that there is a category identifier of the category to which the item information accessed by the user belongs in the category table, the category of the category to which the item information accessed by the user belongs in the category table The number of visits corresponding to the identifier is increased by one, and the most recent access time corresponding to the category identifier of the category to which the item information accessed by the user in the category table belongs is updated to the time when the user accesses the item information.

在一些实施例中,上述创建步骤还包括:响应于确定上述类目表中不存在上述用户访问的物品信息所属类目的类目标识,将上述用户访问的物品信息所属类目的类目标识添加到上述类目表中,将上述用户访问的物品信息所属类目的类目标识的访问次数置为1,将上述用户访问的物品信息所属类目的类目标识对应的最近访问时间置为上述用户访问上述物品信息的时间并存储上述添加操作后的类目表。In some embodiments, the above-mentioned creating step further includes: in response to determining that there is no category identifier of the category to which the item information accessed by the user belongs in the category table, identifying the category of the category to which the item information accessed by the user belongs. Add to the above category table, set the access times of the category ID of the category to which the item information accessed by the user belongs to 1, and set the latest access time corresponding to the category ID of the category to which the item information accessed by the user belongs to The time when the above-mentioned user accesses the above-mentioned item information and the category table after the above-mentioned adding operation is stored.

在一些实施例中,上述创建步骤还包括:将上述类目表中的最近访问时间早于预设时间的类目标识对应的访问次数和最近访问时间置零。In some embodiments, the above-mentioned creating step further includes: zeroing the number of visits and the most recent visit time corresponding to the category identifier whose most recent access time is earlier than the preset time in the above-mentioned category table.

第二方面,本公开的实施例提供了一种用于呈现类目信息的装置,包括:排序单元,被配置成根据用户对预先创建的类目表中的类目的最近访问时间和访问次数,对上述类目表中的类目进行排序,生成候选类目序列;调整单元,被配置成根据上述用户的最近访问类目调整上述候选类目序列中的类目的排序;呈现单元,被配置成按照调整后的类目的排序呈现类目信息。In a second aspect, an embodiment of the present disclosure provides an apparatus for presenting category information, comprising: a sorting unit configured to be based on a user's recent access time and access times to a category in a pre-created category table , sort the categories in the category table to generate a sequence of candidate categories; the adjusting unit is configured to adjust the sorting of categories in the sequence of candidate categories according to the categories recently accessed by the user; the presentation unit is configured to It is configured to present category information according to the adjusted order of categories.

在一些实施例中,上述排序单元进一步被配置成:根据预设的最近访问时间权重和访问次数权重,对上述类目表中的类目的最近访问时间和访问次数加权求和,确定上述类目表中的类目的排序值;按照排序值由大到小对类目表中的类目进行排序,选择排序前预设位的类目生成候选类目序列。In some embodiments, the sorting unit is further configured to: according to a preset weight of the recent access time and the weight of the number of visits, weighted summation of the most recent access time and the number of visits of the categories in the above category table, to determine the above category Sort value of the categories in the category table; sort the categories in the category table according to the sorting value from large to small, and select the category preset before sorting to generate a candidate category sequence.

在一些实施例中,上述调整单元进一步被配置成:响应于确定上述用户的最近访问类目位于上述候选类目序列中,将上述用户的最近访问类目调整至上述候选类目序列的首位。In some embodiments, the adjustment unit is further configured to: in response to determining that the user's recently visited category is in the candidate category sequence, adjust the user's recently visited category to the top of the candidate category sequence.

在一些实施例中,上述调整单元进一步被配置成:响应于确定上述用户的最近访问类目不位于上述候选类目序列中,将上述用户的最近访问类目插入至上述候选类目序列的首位;响应于在首位插入上述用户的最近访问类目后的候选类目序列的长度超过上述候选类目序列的最大长度,将在首位插入上述用户的最近访问类目后的候选类目序列中排序末位的类目删除。In some embodiments, the adjustment unit is further configured to: in response to determining that the user's recently visited category is not located in the candidate category sequence, insert the user's recently visited category into the first position of the candidate category sequence ; In response to the length of the candidate category sequence after inserting the above-mentioned user's recently visited category at the first position exceeding the maximum length of the above-mentioned candidate category sequence, the candidate category sequence after the first insertion of the above-mentioned user's recently visited category will be sorted in the sequence The last category is deleted.

在一些实施例中,上述装置设置于客户端。In some embodiments, the above-mentioned apparatus is provided on the client.

在一些实施例中,上述预先创建的类目表是通过以下创建步骤得到的:创建类目表,类目表中的每一条数据包括类目标识、访问次数、最近访问时间;确定用户访问的物品信息所属类目的类目标识,响应于确定上述类目表中存在用户访问的物品信息所属类目的类目标识,将上述类目表中上述用户访问的物品信息所属类目的类目标识对应的访问次数加一,将上述类目表中上述用户访问的物品信息所属类目的类目标识对应的最近访问时间更新为上述用户访问上述物品信息的时间。In some embodiments, the above-mentioned pre-created category table is obtained through the following creation steps: creating a category table, each piece of data in the category table includes category identification, number of visits, and recent visit time; The category identifier of the category to which the item information belongs, in response to determining that there is a category identifier of the category to which the item information accessed by the user belongs in the category table, the category of the category to which the item information accessed by the user belongs in the category table The number of visits corresponding to the identifier is increased by one, and the most recent access time corresponding to the category identifier of the category to which the item information accessed by the user in the category table belongs is updated to the time when the user accesses the item information.

在一些实施例中,上述创建步骤还包括:响应于确定上述类目表中不存在上述用户访问的物品信息所属类目的类目标识,将上述用户访问的物品信息所属类目的类目标识添加到上述类目表中,将上述用户访问的物品信息所属类目的类目标识的访问次数置为1,将上述用户访问的物品信息所属类目的类目标识对应的最近访问时间置为上述用户访问上述物品信息的时间并存储上述添加操作后的类目表。In some embodiments, the above-mentioned creating step further includes: in response to determining that there is no category identifier of the category to which the item information accessed by the user belongs in the category table, identifying the category of the category to which the item information accessed by the user belongs. Add to the above category table, set the access times of the category ID of the category to which the item information accessed by the user belongs to 1, and set the latest access time corresponding to the category ID of the category to which the item information accessed by the user belongs to The time when the above-mentioned user accesses the above-mentioned item information and the category table after the above-mentioned adding operation is stored.

在一些实施例中,上述创建步骤还包括:将上述类目表中的最近访问时间早于预设时间的类目标识对应的访问次数和最近访问时间置零。In some embodiments, the above-mentioned creating step further includes: zeroing the number of visits and the most recent visit time corresponding to the category identifier whose most recent access time is earlier than the preset time in the above-mentioned category table.

第三方面,本公开的实施例提供了一种电子设备,包括:一个或多个处理器;存储装置,用于存储一个或多个程序,当一个或多个程序被一个或多个处理器执行,使得一个或多个处理器实现如第一方面提供的用于呈现类目信息的方法。In a third aspect, embodiments of the present disclosure provide an electronic device, including: one or more processors; and a storage device for storing one or more programs, when the one or more programs are processed by the one or more processors Execution causes one or more processors to implement the method for presenting category information as provided in the first aspect.

第四方面,本公开的实施例提供了一种计算机可读介质,其上存储有计算机程序,其中,程序被处理器执行时实现第一方面提供的用于呈现类目信息的方法。In a fourth aspect, embodiments of the present disclosure provide a computer-readable medium on which a computer program is stored, wherein the program, when executed by a processor, implements the method for presenting category information provided in the first aspect.

本申请上述实施例的用于呈现类目信息的方法和装置,首先,根据用户对预先创建的类目表中的类目的最近访问时间和访问次数,对上述类目表中的类目进行排序,生成候选类目序列;然后,根据上述用户的最近访问类目调整上述候选类目序列中的类目的排序;最后,按照调整后的类目的排序呈现类目信息。本申请上述实施例的用于呈现类目信息的方法根据用户的最近访问类目,对类目排序后进行呈现,实现了针对不同的用户差异化地呈现类目信息,呈现类目的顺序更符合用户的需求,提高了呈现类目信息的效率。同时,采用类目表的方式可以实现高效的类目信息管理。For the method and device for presenting category information according to the above-mentioned embodiments of the present application, firstly, according to the user's recent access time and number of visits to the categories in the pre-created category table, the categories in the above category table are analyzed. Sorting to generate a candidate category sequence; then, adjusting the ranking of the categories in the candidate category sequence according to the user's most recently visited categories; finally, presenting the category information according to the adjusted category ranking. The method for presenting category information according to the above-mentioned embodiments of the present application sorts the categories and presents them according to the categories recently accessed by the user, thereby realizing the differentiated presentation of category information for different users, and the order of presenting categories is improved. It meets the needs of users and improves the efficiency of presenting category information. At the same time, efficient category information management can be achieved by using the category table.

在一些实现方式中,把呈现类目信息的处理过程从后台转移到客户端,解决了流量、隐私,特别是数据实效性等一系列的问题。In some implementations, the process of presenting category information is transferred from the background to the client, which solves a series of problems such as traffic, privacy, and especially data validity.

附图说明Description of drawings

通过阅读参照以下附图所作的对非限制性实施例所作的详细描述,本申请的其它特征、目的和优点将会变得更明显:Other features, objects and advantages of the present application will become more apparent by reading the detailed description of non-limiting embodiments made with reference to the following drawings:

图1是本申请实施例可以应用于其中的示例性系统架构图;FIG. 1 is an exemplary system architecture diagram to which embodiments of the present application may be applied;

图2是根据本申请的用于呈现类目信息的方法的一个实施例的流程图;FIG. 2 is a flowchart of one embodiment of a method for presenting category information according to the present application;

图3是根据本申请实施例的用于呈现类目信息的方法的一个应用场景的示意图;3 is a schematic diagram of an application scenario of the method for presenting category information according to an embodiment of the present application;

图4是根据本申请的用于呈现类目信息的方法的另一个实施例的流程图;4 is a flowchart of another embodiment of a method for presenting category information according to the present application;

图5是根据本申请实施例的用于呈现类目信息的方法的一个应用场景的示意图;5 is a schematic diagram of an application scenario of the method for presenting category information according to an embodiment of the present application;

图6是根据本申请的用于呈现类目信息的装置的一个实施例的结构示意图;6 is a schematic structural diagram of an embodiment of an apparatus for presenting category information according to the present application;

图7是适于用来实现本申请实施例的服务器的计算机系统的结构示意图。FIG. 7 is a schematic structural diagram of a computer system suitable for implementing the server of the embodiment of the present application.

具体实施方式Detailed ways

下面结合附图和实施例对本申请作进一步的详细说明。可以理解的是,此处所描述的具体实施例仅仅用于解释相关发明,而非对该发明的限定。另外还需要说明的是,为了便于描述,附图中仅示出了与有关发明相关的部分。The present application will be further described in detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the related invention, but not to limit the invention. In addition, it should be noted that, for the convenience of description, only the parts related to the related invention are shown in the drawings.

需要说明的是,在不冲突的情况下,本申请中的实施例及实施例中的特征可以相互组合。下面将参考附图并结合实施例来详细说明本申请。It should be noted that the embodiments in the present application and the features of the embodiments may be combined with each other in the case of no conflict. The present application will be described in detail below with reference to the accompanying drawings and in conjunction with the embodiments.

图1示出了可以应用本申请的用于呈现类目信息的方法或用于呈现类目信息的装置的示例性系统架构100。FIG. 1 shows an exemplary system architecture 100 to which the method for presenting category information or the apparatus for presenting category information of the present application may be applied.

如图1所示,系统架构100可以包括用户101,用于呈现类目信息的终端设备102,网络103,服务器104。As shown in FIG. 1 , the system architecture 100 may include a user 101 , a terminal device 102 for presenting category information, a network 103 , and a server 104 .

用户可以通过安装在终端设备102上的屏幕浏览网络内容等,网络内容可以是文字,可以是图片,可以是视频,还可以是其他可以被浏览的网络内容,在此不做具体限定。终端设备102上可以安装有各种内容浏览应用,例如浏览器应用、购物类应用、社交平台软件等。The user can browse network content through the screen installed on the terminal device 102. The network content can be text, pictures, videos, or other browseable network content, which is not specifically limited here. Various content browsing applications, such as browser applications, shopping applications, social platform software, etc., may be installed on the terminal device 102 .

终端设备102可以是硬件,也可以是软件。当终端设备102为硬件时,可以是具有显示屏并且支持网络内容浏览的各种电子设备,包括但不限于智能手机、平板电脑、膝上型便携计算机和台式计算机等等。当终端设备102为软件时,可以安装在上述所列举的电子设备中。其可以实现成多个软件或软件模块(例如用来提供分布式服务的多个软件或软件模块),也可以实现成单个软件或软件模块。在此不做具体限定。The terminal device 102 may be hardware or software. When the terminal device 102 is hardware, it can be various electronic devices having a display screen and supporting web content browsing, including but not limited to smart phones, tablet computers, laptop computers, desktop computers, and the like. When the terminal device 102 is software, it can be installed in the electronic devices listed above. It can be implemented as multiple software or software modules (eg, multiple software or software modules for providing distributed services), or as a single software or software module. There is no specific limitation here.

服务器104可以是提供各种服务的服务器,例如为终端设备102上网络应用的后台服务器。后台服务器可以接收终端设备102上报的类目排序信息,在类目信息库中查找相应的类目信息(文字、图片以及视频等网络内容),按照上述类目排序信息反馈给终端设备102,用以呈现给用户101。The server 104 may be a server that provides various services, for example, a background server of a network application on the terminal device 102 . The background server can receive the category sorting information reported by the terminal device 102, look up the corresponding category information (web content such as text, pictures, and videos) in the category information database, and feed it back to the terminal device 102 according to the above category sorting information. to present to the user 101 .

需要说明的是,本申请实施例所提供的用于呈现类目信息的方法可以通过终端设备102执行。相应地,用于呈现类目信息的装置可以设置于终端设备102中。It should be noted that, the method for presenting category information provided by the embodiments of the present application may be executed by the terminal device 102 . Correspondingly, the means for presenting category information may be provided in the terminal device 102 .

应该理解,图1中的终端设备、网络、服务器的数目仅仅是示意性的。根据实现需要,可以具有任意数目的终端设备、网络和服务器。It should be understood that the numbers of terminal devices, networks, and servers in FIG. 1 are only illustrative. There can be any number of terminal devices, networks and servers according to implementation needs.

继续参考图2,其示出了根据本申请的用于呈现类目信息的方法的一个实施例的流程200。该用于呈现类目信息的方法,包括以下步骤:Continuing to refer to FIG. 2 , a flow 200 of one embodiment of a method for presenting category information according to the present application is shown. The method for presenting category information includes the following steps:

步骤201,根据用户对预先创建的类目表中的类目的最近访问时间和访问次数,对类目表中的类目进行排序,生成候选类目序列。Step 201 , sort the categories in the category table according to the recent access time and the number of visits of the categories in the pre-created category table by the user to generate a candidate category sequence.

在本实施例中,上述预先创建的类目表中包含类目的最近访问时间和访问次数,其中,上述用户是指定的用户,例如使用该终端设备的用户,或者指定的用户ID对应的用户;最近访问时间是该用户最近一次访问该类目下的产品内容的时间;访问次数是统计得出的,可以是设定时长内的该用户访问该类目下产品内容的次数,上述设定时长是根据实际应用场景进行设定的到当前时刻的时间段,例如,一个月,一星期,60天等,在此不做具体限定。执行主体可以根据该用户的最近访问时间和访问次数,对上述类目表中的类目进行排序,生成候选类目序列。具体地,执行主体可以根据访问次数的大小进行排序,也可以根据最近访问时间的顺序进行排序,还可以根据其他指定的排序方式进行排序,在此不做具体限定。In this embodiment, the above-mentioned pre-created category table includes the most recent visit time and the number of visits of the category, wherein the above-mentioned user is a designated user, such as a user using the terminal device, or a user corresponding to a designated user ID ; The most recent visit time is the last time the user visited the product content under this category; the number of visits is obtained by statistics, which can be the number of times the user has accessed the product content under this category within a set period of time. The duration is the time period from the current moment set according to the actual application scenario, for example, one month, one week, 60 days, etc., which is not specifically limited here. The executive body may sort the categories in the above category table according to the user's recent access time and the number of visits to generate a candidate category sequence. Specifically, the execution subjects may be sorted according to the size of the number of accesses, or may be sorted according to the order of the most recent access time, or may be sorted according to other specified sorting methods, which are not specifically limited here.

访问次数访问次数访问次数访问次数访问次数可选地,上述用于呈现类目信息的方法应用于客户端,能够克服服务端收集用户信息有限而导致分类的排序信息还是不够实时和准确的缺点,可以避免导致用户隐私泄露,从而可以获取用户更多的信息(例如浏览记录、购物记录),而且在客户端可以实时获取这些信息,解决了流量、隐私,特别是数据实效性等一系列的问题。The number of visits The number of visits The number of visits The number of visits The number of visits Optionally, the above method for presenting category information is applied to the client, which can overcome the disadvantage that the sorting information of the categories is not real-time and accurate due to the limited collection of user information by the server, It can avoid leakage of user privacy, so that more information of users (such as browsing records and shopping records) can be obtained, and these information can be obtained in real time on the client side, which solves a series of problems such as traffic, privacy, and especially data effectiveness. .

可选地,上述预先创建的类目表是通过以下创建步骤得到的:首先,创建类目表,类目表中的每一条数据包括类目标识、访问次数、最近访问时间;然后,执行主体确定用户访问的物品信息所属类目的类目标识,响应于确定上述类目表中存在用户访问的物品信息所属类目的类目标识,将上述类目表中上述用户访问的物品信息所属类目的类目标识对应的访问次数加一,将上述类目表中上述用户访问的物品信息所属类目的类目标识对应的最近访问时间更新为上述用户访问上述物品信息的时间。Optionally, the above-mentioned pre-created category table is obtained through the following creation steps: first, a category table is created, and each piece of data in the category table includes category identification, number of visits, and recent access time; then, the execution body Determine the category identifier of the category to which the item information accessed by the user belongs, and in response to determining that there is a category identifier of the category to which the item information accessed by the user belongs in the category table, classifying the category of the item information accessed by the user in the category table into a category The number of visits corresponding to the target category identifier is increased by one, and the most recent access time corresponding to the category identifier of the category to which the item information accessed by the user in the category table belongs is updated to the time when the user accesses the item information.

上述类目标识可以是预先设置的用于标识类目的信息,例如由数字、字母等组成的字符串,或者文字标识,还可以是图片等其他格式的标识信息。。上述物品信息可以是指该用户浏览到网络内容中所涉及的物品信息,例如购物类应用中物品的标题、图片、视频等。上述创建类目表的执行主体可以是客户端,也可以是服务端,客户端创建类目表可以是通过创建一个包括类目标识、访问次数、最近访问时间等字段的空表,然后根据用户的访问记录对该类目表进行添加内容;服务端创建类目表可以是通过将预先设置的多个常用类目组成的多条数据添加到类目表中,将上述类目表中的访问次数、最近访问时间设定初始值,例如0,之后将该服务端创建的类目表发送给客户端,供客户端使用。The above category identifier may be preset information for identifying categories, such as a character string composed of numbers, letters, etc., or a text identifier, and may also be identification information in other formats such as pictures. . The above-mentioned item information may refer to item information involved in the web content browsed by the user, such as the title, picture, video, etc. of the item in a shopping application. The execution subject of the above-mentioned creation of the category table can be the client or the server. The client can create a category table by creating an empty table including fields such as category identification, number of visits, and recent access time, and then according to the user. Add content to the category table by the access records of Set the initial value of the number of times and the most recent access time, such as 0, and then send the category table created by the server to the client for the client to use.

可选地,上述创建步骤还可以包括:响应于确定上述类目表中不存在上述用户访问的物品信息所属类目的类目标识,将上述用户访问的物品信息所属类目的类目标识添加到上述类目表中,将上述用户访问的物品信息所属类目的类目标识的访问次数置为1,将上述用户访问的物品信息所属类目的类目标识对应的最近访问时间置为上述用户访问上述物品信息的时间并存储上述添加操作后的类目表。Optionally, the above-mentioned creating step may further include: in response to determining that the category identification of the category to which the item information accessed by the user does not exist in the category table, adding the category identification of the category to which the item information accessed by the user belongs. In the above category table, set the number of visits of the category ID of the category to which the item information accessed by the user belongs to 1, and set the latest access time corresponding to the category ID of the category to which the item information accessed by the user belongs to the above. The time when the user accesses the above-mentioned item information and stores the category table after the above-mentioned adding operation.

可选地,上述创建步骤还可以包括:将上述类目表中的最近访问时间早于预设时间的类目标识对应的访问次数和最近访问时间置零。上述预设时间可以根据实际应用场景进行设置,例如60天前、7天前等时间,在此不做具体限定。Optionally, the above-mentioned creating step may further include: zeroing the number of visits and the most recent visit time corresponding to the category identifier whose most recent access time is earlier than the preset time in the above-mentioned category table. The above preset time can be set according to the actual application scenario, for example, 60 days ago, 7 days ago, etc., which are not specifically limited here.

通过创建类目表并采用上述方式对类目表进行维护,可以实现类目信息的高效管理,降低类目信息所占用的内存空间。在上述方法应用于客户端时,可以避免客户端本地管理类目信息占用过多存储和计算资源而影响客户端的数据处理效率。By creating a category table and maintaining the category table in the above manner, efficient management of category information can be achieved, and memory space occupied by category information can be reduced. When the above method is applied to the client, it can avoid that the client's local management category information occupies too much storage and computing resources and affects the data processing efficiency of the client.

步骤202,根据用户的最近访问类目调整候选类目序列中的类目的排序。Step 202: Adjust the ranking of the categories in the candidate category sequence according to the category recently accessed by the user.

在本实施例中,最近访问类目通常是指用户在当前时刻访问的最后一个类目,也可以是指用户的历史访问类目中的最后一个类目。执行主体可以通过以下方式调整候选类目序列中的类目的排序:首先确定用户的最近访问类目是否在该候选类目序列中,若已存在,则将上述类目表中该最近访问类目的访问次数加一,以及将该最近访问类目的最近访问时间更新为用户最后访问该最近访问类目的时刻,然后对上述操作后的类目表重新进行类目排序,例如按照访问次数大小进行排序或按照最近访问时间早晚进行排序。In this embodiment, the recently accessed category usually refers to the last category accessed by the user at the current moment, and may also refer to the last category in the user's historically accessed categories. The executive body can adjust the ordering of the categories in the candidate category sequence in the following ways: first determine whether the user's most recently accessed category is in the candidate category sequence, and if it already exists, put the most recently accessed category in the above category table. Add one to the number of purpose visits, and update the last visit time of the recently visited category to the time when the user last accessed the recently visited category, and then re-sort the category table after the above operation, for example, according to the number of visits Sort by size or by time of most recent access.

步骤203,按照调整后的类目的排序呈现类目信息。Step 203: Present category information according to the adjusted category order.

在本实施例中,执行主体可以将经过步骤202调整后的类目序列呈现到页面上,可选地地,上述用于呈现类目信息的方法,可以应用于客户端,此时,执行主体可以为客户端,则按照调整后的类目的排序呈现在该客户端的显示页面。In this embodiment, the execution body may present the category sequence adjusted in step 202 on the page. Optionally, the above method for presenting category information may be applied to the client. At this time, the execution body If it can be a client, it will be presented on the display page of the client according to the order of the adjusted categories.

继续参见图3,图3是根据本实施例的用于呈现类目信息的方法的应用场景的一个示意图。在图3的应用场景300中,客户端301根据用户302对预先创建的类目表303中的类目的最近访问时间和访问次数“类目a,12点10分,3次;类目b,11点8分,2次;类目c,10点30分,4次;类目d,10点13分,3次;类目e,9点7分,5次;类目f,8点10分,7次;类目g,5点10分,3次”进行排序,生成候选类目序列304,具体地,客户端301按照上述类目表中类目的访问次数从大到小进行排序,其中,访问次数相同的类目按照最近访问时间早晚进行排序;最终得到候选类目序列304“类目f,8点10分,7次;类目e,9点7分,5次;类目c,10点30分,4次;类目a,12点10分,3次;类目d,10点13分,3次;类目g,5点10分,3次;类目b,11点8分,2次”;根据上述用户的最近访问类目305“类目h,13点18分,1次”调整上述候选类目序列304中的类目的排序,具体地,可以将上述最近访问类目305添加到上述候选类目序列304中的首位,得到类目序列306“类目h,13点18分,1次;类目f,8点10分,7次;类目e,9点7分,5次;类目c,10点30分,4次;类目a,12点10分,3次;类目d,10点13分,3次;类目g,5点10分,3次;类目b,11点8分,2次”;按照调整后的类目的排序306呈现类目信息。Continue to refer to FIG. 3 , which is a schematic diagram of an application scenario of the method for presenting category information according to this embodiment. In the application scenario 300 in FIG. 3 , the client 301 accesses the categories in the pre-created category table 303 according to the latest access time and the number of visits by the user 302 "category a, 12:10, 3 times; category b , 11:8, 2 times; category c, 10:30, 4 times; category d, 10:13, 3 times; category e, 9:7, 5 times; category f, 8 10 points, 7 times; category g, 5:10 points, 3 times" to generate a candidate category sequence 304. Specifically, the client 301 visits the categories in descending order according to the categories in the above category table. Sorting, in which the categories with the same number of visits are sorted according to the most recent visit time; finally get the candidate category sequence 304 "category f, 8:10, 7 times; category e, 9:7, 5 times ;Category c, 10:30, 4 times; Category a, 12:10, 3 times; Category D, 10:13, 3 times; Category g, 5:10, 3 times; item b, 11:08, 2 times"; adjust the ranking of the categories in the candidate category sequence 304 according to the user's most recent access category 305 "category h, 13:18, 1 time", specifically , the above recently visited category 305 can be added to the first position in the above candidate category sequence 304 to obtain a category sequence 306 "Category h, 13:18, 1 time; category f, 8:10, 7 times ; Category e, 9:7, 5 times; Category c, 10:30, 4 times; Category a, 12:10, 3 times; Category D, 10:13, 3 times; Category g, 5:10, 3 times; Category b, 11:8, 2 times"; category information is presented 306 according to the adjusted category order.

本申请实施例提供的用于呈现类目信息的方法。客户端根据用户的最近访问类目,对类目排序后进行呈现,实现了针对不同的用户差异化地呈现类目信息,呈现类目的顺序更符合用户的需求,提高了呈现类目信息的效率。。The method for presenting category information provided by the embodiments of the present application. The client side sorts the categories and presents them according to the user's most recently visited categories, realizing the differentiated presentation of category information for different users. efficiency. .

继续参考图4,其示出了根据本申请的用于呈现类目信息的方法的一个实施例的流程400。该用于呈现类目信息的方法,包括以下步骤:Continuing to refer to FIG. 4 , it shows a flow 400 of one embodiment of a method for presenting category information according to the present application. The method for presenting category information includes the following steps:

步骤401,根据预设的最近访问时间权重和访问次数权重,对类目表中的类目的最近访问时间和访问次数加权求和,确定类目表中的类目的排序值。Step 401 , according to the preset weight of recent access time and the weight of access times, weighted summation of the most recent access time and access times of the categories in the category table, to determine the ranking value of the categories in the category table.

在本实施例中,最近访问时间权重和访问次数权重可以是根据主观赋权法或客观赋权法进行设置的数值,在此不做具体限定,上述主观赋权法可以是层次分析法(AHP),也可以是德尔菲法(Delphi Method)。上述客观赋权法可以是主成分分析法,也可以是变异系数法。可选地,执行主体可以遍历类目表中的类目,将最近访问时间权重与最近访问时间的乘积和访问次数权重与访问次数的乘积相加得到类目表中的类目的排序值。执行主体通过上述最近访问时间权重和访问次数权重确定类目表中的类目的排序值。根据访问次数的权重设置的不同,可以确定访问次数在类目排序中的影响大小。例如,将上述访问次数权重设置的较大,则排序值较大的类目即可以确定为访问次数较多的类目,访问次数较多则表明该类目的热度较高,进而通过排序值的大小确定类目的热度。根据最近访问时间的权重设置的不同,可以确定最近访问时间在类目排序中的影响大小。例如,将最近访问时间的权重设置的较大,则排序值较大的类目即可以确定为最近访问时间较晚的类目,最近访问时间较晚则表明该类目是被最近时间访问的,进而通过排序值的大小确定类目的近期热度。再例如,将上述最近访问时间权重和访问次数权重设置的较为接近,则可以从排序值较大的类目中得到近期访问次数较多的类目,作为用户的潜在感兴趣的类目,可以用于后续推荐给用户,例如,将该类目排列在较靠前的位置。在购物类应用中,有助于提升用户访问到感兴趣信息的效率,提升用户的购物体验。In this embodiment, the weight of the most recent access time and the weight of the number of visits may be values set according to the subjective weighting method or the objective weighting method, which is not specifically limited here, and the above-mentioned subjective weighting method may be the Analytic Hierarchy Process (AHP) ), or the Delphi Method. The above objective weighting method may be principal component analysis method or variation coefficient method. Optionally, the executive body may traverse the categories in the category table, and add the product of the weight of the most recent access time and the recent access time and the product of the weight of the number of visits and the number of visits to obtain the ranking value of the categories in the category table. The execution subject determines the ranking value of the categories in the category table according to the weight of the most recent access time and the weight of the number of visits. According to the different weight settings of the number of visits, the influence of the number of visits in the category sorting can be determined. For example, if the weight of the above number of visits is set to be larger, the category with a larger ranking value can be determined as a category with more visits, and a higher number of visits indicates that the category is more popular, and then the category with a higher ranking value can be determined as a category with more visits. The size of the category determines the popularity of the category. According to the different weight settings of the recent access time, the influence of the recent access time in the category ranking can be determined. For example, if the weight of the recent access time is set to be larger, the category with a larger ranking value can be determined as a category with a late access time, and a late access time indicates that the category was accessed recently. , and then determine the recent popularity of the category by the size of the ranking value. For another example, if the weight of the recent access time and the weight of the number of visits are set closer to each other, the category with more recent visits can be obtained from the category with a larger ranking value. It is used for subsequent recommendations to users, for example, arranging the category in a higher position. In shopping applications, it helps to improve the efficiency of users accessing information of interest and improve the shopping experience of users.

可选地,执行主体还可以按照如下公式计算排序值:y=count*w_count+time/a*w_time,其中,y表示排序值,count表示访问次数,w_count表示访问次数权重,time表示最近访问时间(转换成Unix时间戳的时间),w_time表示最近访问时间权重,=表示等号,*表示乘号,+表示加号,/表示除号,a表示常量,由于Unix时间戳的值比较大,不便于进行计算,所以把时间戳除以一个常量a,这个常量具体的值,可以根据实际的场景进行设定和调整,这样就可以优化计算的结果。用上述方法,计算每一个类目的排序值,然后对这些值进行排序,即可获得利用用户热度进行分类排序的目的。上述访问次数和最近访问时间可以体现类目的用户热度。Optionally, the execution body may also calculate the ranking value according to the following formula: y=count*w_count+time/a*w_time, where y represents the ranking value, count represents the number of visits, w_count represents the weight of the number of visits, and time represents the latest access time (time converted to Unix timestamp), w_time represents the weight of the most recent access time, = represents an equal sign, * represents a multiplication sign, + represents a plus sign, / represents a division sign, and a represents a constant, because the value of the Unix timestamp is relatively large, It is inconvenient to calculate, so divide the timestamp by a constant a. The specific value of this constant can be set and adjusted according to the actual scene, so that the calculation result can be optimized. Using the above method, calculate the ranking value of each category, and then sort these values, you can obtain the purpose of sorting and sorting by user popularity. The above number of visits and the most recent visit time can reflect the user popularity of the category.

可选地,上述用于呈现类目信息的方法应用于客户端,能够克服服务端收集用户信息有限而导致分类的排序信息还是不够实时和准确的缺点,可以避免导致用户隐私泄露,从而可以获取用户更多的信息(例如浏览记录、购物记录),而且在客户端可以实时获取这些信息,解决了流量、隐私,特别是数据实效性等一系列的问题。Optionally, the above-mentioned method for presenting category information is applied to the client, which can overcome the disadvantage that the sorting information of the classification is not real-time and accurate due to the limited collection of user information by the server, and can avoid leakage of user privacy, so that it is possible to obtain Users have more information (such as browsing records, shopping records), and the client can obtain this information in real time, solving a series of problems such as traffic, privacy, and especially data effectiveness.

可选地,上述预先创建的类目表可以通过以下创建步骤得到:创建类目表,类目表中的每一条数据包括类目标识、访问次数、最近访问时间;确定用户访问的物品信息所属类目的类目标识,响应于确定上述类目表中存在用户访问的物品信息所属类目的类目标识,将上述类目表中上述用户访问的物品信息所属类目的类目标识对应的访问次数加一,将上述类目表中上述用户访问的物品信息所属类目的类目标识对应的最近访问时间更新为上述用户访问上述物品信息的时间。Optionally, the above-mentioned pre-created category table can be obtained through the following creation steps: create a category table, and each piece of data in the category table includes category identification, number of visits, and recent visit time; determine the belonging of the item information accessed by the user. The category identification of the category, in response to determining that there is a category identification of the category to which the item information accessed by the user belongs in the category table, the category identification of the category to which the item information accessed by the user in the category table belongs is corresponding to the category identification. The number of visits is increased by one, and the most recent visit time corresponding to the category identifier of the category to which the item information accessed by the user in the category table belongs is updated to the time when the user accesses the item information.

上述类目标识可以根据实际需要进行设置,例如数字、字母等字符,在此不做具体限定。上述物品信息可以是指该用户浏览到网络内容中所涉及的物品信息,例如购物类应用中物品的标题、图片、视频等。上述创建类目表的执行主体可以是客户端,也可以是服务端,客户端创建类目表可以是通过创建一个包括类目标识、访问次数、最近访问时间等字段的空表,然后根据用户的访问记录对该类目表进行添加内容;服务端创建类目表可以是通过将预先设置的多个常用类目组成的多条数据添加到类目表中,将上述类目表中的访问次数、最近访问时间设定初始值,例如0,之后将该服务端创建的类目表发送给客户端,供客户端使用。The above category identifiers can be set according to actual needs, such as numbers, letters and other characters, which are not specifically limited here. The above-mentioned item information may refer to item information involved in the web content browsed by the user, such as the title, picture, video, etc. of the item in a shopping application. The execution subject of the above-mentioned creation of the category table can be the client or the server. The client can create a category table by creating an empty table including fields such as category identification, number of visits, and recent access time, and then according to the user. Add content to the category table by the access records of Set the initial value of the number of times and the most recent access time, such as 0, and then send the category table created by the server to the client for the client to use.

可选地,上述创建步骤还可以包括:响应于确定上述类目表中不存在上述用户访问的物品信息所属类目的类目标识,将上述用户访问的物品信息所属类目的类目标识添加到上述类目表中,将上述用户访问的物品信息所属类目的类目标识的访问次数置为1,将上述用户访问的物品信息所属类目的类目标识对应的最近访问时间置为上述用户访问上述物品信息的时间并存储上述添加操作后的类目表。Optionally, the above-mentioned creating step may further include: in response to determining that the category identification of the category to which the item information accessed by the user does not exist in the category table, adding the category identification of the category to which the item information accessed by the user belongs. In the above category table, set the number of visits of the category ID of the category to which the item information accessed by the user belongs to 1, and set the latest access time corresponding to the category ID of the category to which the item information accessed by the user belongs to the above. The time when the user accesses the above-mentioned item information and stores the category table after the above-mentioned adding operation.

可选地,上述创建步骤还可以包括:将上述类目表中的最近访问时间早于预设时间的类目标识对应的访问次数和最近访问时间置零。上述预设时间可以根据实际应用场景进行设置,例如30天前、10天前等时间,在此不做具体限定。Optionally, the above-mentioned creating step may further include: zeroing the number of visits and the most recent visit time corresponding to the category identifier whose most recent access time is earlier than the preset time in the above-mentioned category table. The above preset time can be set according to the actual application scenario, for example, 30 days ago, 10 days ago, etc., which are not specifically limited here.

步骤402,按照排序值由大到小对类目表中的类目进行排序,选择排序前预设位的类目生成候选类目序列。Step 402 , sort the categories in the category table according to the sorting value in descending order, and select the categories preset before the sorting to generate a candidate category sequence.

在本实施例中,执行主体可以选择排序前预设位的类目生成候选类目序列,也就是选择排序值较大的前预设数目个类目作为候选类目序列。预设数目可以根据实际需要进行设定,例如可以根据客户端显示页面的大小进行设定。In this embodiment, the execution subject may select the categories preset before sorting to generate the candidate category sequence, that is, select the first preset number of categories with larger sorting values as the candidate category sequence. The preset number can be set according to actual needs, for example, it can be set according to the size of the page displayed by the client.

步骤403,根据用户的最近访问类目调整候选类目序列中的类目的排序。Step 403: Adjust the ranking of the categories in the candidate category sequence according to the category recently accessed by the user.

在本实施例中,最近访问类目通常是指用户在当前时刻访问的最后一个类目,也可以是指用户的历史访问类目中的最后一个类目。执行主体可以通过以下方式调整候选类目序列中的类目的排序:首先确定用户的最近访问类目是否在该候选类目序列中,若已存在,则将上述类目表中该最近访问类目的访问次数加一,以及将该最近访问类目的最近访问时间更新为用户最后访问该最近访问类目的时刻,然后对上述操作后的类目表重新进行类目排序,例如按照访问次数大小进行排序或按照最近访问时间早晚进行排序。In this embodiment, the recently accessed category usually refers to the last category accessed by the user at the current moment, and may also refer to the last category in the user's historically accessed categories. The executive body can adjust the ordering of the categories in the candidate category sequence in the following ways: first determine whether the user's most recently accessed category is in the candidate category sequence, and if it already exists, put the most recently accessed category in the above category table. Add one to the number of purpose visits, and update the last visit time of the recently visited category to the time when the user last accessed the recently visited category, and then re-sort the category table after the above operation, for example, according to the number of visits Sort by size or by time of most recent access.

可选地,上述根据上述用户的最近访问类目调整上述候选类目序列中的类目的排序,还可以包括:首先确定用户的最近访问类目是否在该候选类目序列中,若已存在,将所述用户的最近访问类目调整至所述候选类目序列的首位。执行主体将用户的最近访问类目调整至候选类目序列的首位可以在显示页面显示的时候,该最近访问类目排在首位,通常用户的最近访问类目大概率是用户最近感兴趣的类目,因此该最近访问类目排在首位,可以提升用户的访问体验和查找效率。Optionally, the above-mentioned adjusting the ranking of the categories in the above-mentioned candidate category sequence according to the above-mentioned user's most recently visited category may also include: firstly determining whether the user's most recently visited category is in the candidate category sequence, and if there is an existing category. , and adjust the user's recently visited category to the top of the candidate category sequence. The executive body adjusts the user's recently visited category to the top of the candidate category sequence. When the display page is displayed, the recently visited category is ranked first. Usually, the user's recently visited category has a high probability of being the category that the user is interested in recently. Therefore, the recently visited category ranks first, which can improve the user's visit experience and search efficiency.

可选地,上述根据上述用户的最近访问类目调整上述候选类目序列中的类目的排序,还可以包括:响应于确定上述用户的最近访问类目不位于上述候选类目序列中,将上述用户的最近访问类目插入至上述候选类目序列的首位;响应于在首位插入上述用户的最近访问类目后的候选类目序列的长度超过上述候选类目序列的最大长度,将在首位插入上述用户的最近访问类目后的候选类目序列中排序末位的类目删除。执行主体将用户的最近访问类目插入至候选类目序列的首位可以在显示页面显示的时候,该最近访问类目排在首位,用户更明显的可以查看到,有助于用户点击查看,通常用户的最近访问类目大概率是用户最近感兴趣的类目,因此该最近访问类目排在首位,可以提升用户的访问体验和查找效率。Optionally, the above-mentioned adjusting the ranking of the categories in the above-mentioned candidate category sequence according to the above-mentioned user's recently visited categories may also include: in response to determining that the above-mentioned user's recently visited categories are not located in the above-mentioned candidate category sequence, adding The most recently visited category of the above-mentioned user is inserted into the first position of the above-mentioned candidate category sequence; in response to the length of the candidate category sequence after inserting the above-mentioned user's recently visited category at the first position exceeds the maximum length of the above-mentioned candidate category sequence, the first position will be The last category in the sequence of candidate categories after being inserted into the most recently accessed category of the above-mentioned user is deleted. The executive body inserts the user's recently visited category into the first position of the candidate category sequence. When the display page is displayed, the recently visited category is ranked first, and the user can see it more clearly, which is helpful for the user to click to view. Usually The user's recently visited category has a high probability that the user is interested in the category recently, so the recently visited category is ranked first, which can improve the user's visit experience and search efficiency.

上述最大长度可以根据实际应用场景进行设置,例如可以根据客户端显示页面的大小进行设定。具体例如,最大长度为8,则候选类目序列中最多具有8个类目。例如,最大长度为8,则候选类目序列中最多具有8个类目。通过上述方法执行主体可以得到设定的最大长度范围内的候选类目序列。上述方法是考虑到如果数据最近被访问过,那么将来被访问的几率也更高。上述方法运用到的是LRU(Least recently used,最近最少使用)算法根据数据的历史访问记录来进行淘汰数据。根据数据的历史访问记录来进行淘汰数据。该算法的主要思想如下:The above-mentioned maximum length can be set according to the actual application scenario, for example, can be set according to the size of the page displayed by the client. Specifically, for example, if the maximum length is 8, there are at most 8 categories in the candidate category sequence. For example, if the maximum length is 8, there are at most 8 categories in the candidate category sequence. The execution subject of the above method can obtain the candidate category sequence within the set maximum length range. The above approach takes into account that if the data has been accessed recently, the probability of being accessed in the future is also higher. The above method uses the LRU (Least recently used, least recently used) algorithm to eliminate data according to the historical access records of the data. The data is eliminated according to the historical access records of the data. The main idea of the algorithm is as follows:

LRU算法一般会使用一个链表保存数据,如图5所示,建立一个能存储8个类目ID(类目标识)的链表结构,具体的处理步骤如下:首先,当用户访问一个新的类目信息的时候,需要把该类目ID插入到链表头部,但是在此之前,要首先检索链表中是否已经存在了该类目ID;然后,如果链表中已经存在该类目ID,则将该类目ID移到链表头部;如果链表中不存在,则将该类目ID插入到链表头部;最后,当链表满的时候,将链表尾部的类目ID丢弃。这样,把LRU的链表中的类目ID插入到根据用户热度(即访问次数和最近访问时间)的计算的排序结果前面,完成了兼顾用户热度和LRU算法的计算结果。其中,上述中LRU的链表保存的数据个数(即上述步骤405中候选类目序列的最大长度)也可以根据实际情况进行调整。The LRU algorithm generally uses a linked list to save data. As shown in Figure 5, a linked list structure that can store 8 category IDs (category IDs) is established. The specific processing steps are as follows: First, when the user accesses a new category When the information is used, the category ID needs to be inserted into the head of the linked list, but before that, it is necessary to first check whether the category ID already exists in the linked list; then, if the category ID already exists in the linked list, the The category ID is moved to the head of the linked list; if the linked list does not exist, the category ID is inserted into the head of the linked list; finally, when the linked list is full, the category ID at the end of the linked list is discarded. In this way, the category ID in the LRU's linked list is inserted before the sorting result calculated according to the user's popularity (ie the number of visits and the most recent visit time), and the calculation result considering both the user's popularity and the LRU algorithm is completed. The number of data stored in the linked list of the LRU (that is, the maximum length of the candidate category sequence in the above step 405 ) can also be adjusted according to the actual situation.

步骤404,按照调整后的类目的排序呈现类目信息。Step 404 , present category information according to the adjusted category order.

在本实施例中,执行主体可以将经过步骤403调整后的类目序列呈现到页面上,可选地,上述用于呈现类目信息的方法,可以应用于客户端,此时,执行主体可以为客户端,则按照调整后的类目的排序呈现在该客户端的显示页面。In this embodiment, the execution body may present the category sequence adjusted in step 403 on the page. Optionally, the above method for presenting category information may be applied to the client. At this time, the execution body may If it is a client, it will be presented on the display page of the client according to the order of the adjusted categories.

进一步参考图6,作为对上述各图所示方法的实现,本申请提供了一种用于呈现类目信息的装置的一个实施例,该装置实施例与图2所示的方法实施例相对应,该装置具体可以应用于各种电子设备中。Further referring to FIG. 6 , as an implementation of the methods shown in the above figures, the present application provides an embodiment of an apparatus for presenting category information, and the apparatus embodiment corresponds to the method embodiment shown in FIG. 2 . , the device can be specifically applied to various electronic devices.

如图6所示,本实施例上述的用于呈现类目信息的装置600包括:排序单元601,被配置成根据用户对预先创建的类目表中的类目的最近访问时间和访问次数,对上述类目表中的类目进行排序,生成候选类目序列;调整单元602,被配置成根据上述用户的最近访问类目调整上述候选类目序列中的类目的排序;呈现单元603,被配置成按照调整后的类目的排序呈现类目信息。As shown in FIG. 6 , the above-mentioned apparatus 600 for presenting category information in this embodiment includes: a sorting unit 601, which is configured to, according to the most recent access time and the number of accesses to the categories in the pre-created category table by the user, Sorting the categories in the above-mentioned category table to generate a sequence of candidate categories; the adjusting unit 602 is configured to adjust the sorting of the categories in the above-mentioned candidate category sequence according to the categories recently accessed by the above-mentioned users; the presenting unit 603, is configured to present the category information according to the adjusted ordering of the categories.

在本实施例中,用于呈现类目信息的装置600中:排序单元601、调整单元602和呈现单元603的具体处理及其所带来的技术效果可分别参考图2对应实施例中的步骤201、步骤202和步骤203的相关说明,在此不再赘述。In this embodiment, in the apparatus 600 for presenting category information: the specific processing of the sorting unit 601 , the adjusting unit 602 and the presenting unit 603 and the technical effects brought about by the sorting unit 601 , and the technical effects brought about by them may refer to the steps in the corresponding embodiment of FIG. 2 respectively. The related descriptions of step 201 , step 202 and step 203 will not be repeated here.

在本实施例的一些可选的实现方式中,上述排序单元601进一步被配置成:根据预设的最近访问时间权重和访问次数权重,对上述类目表中的类目的最近访问时间和访问次数加权求和,确定上述类目表中的类目的排序值;按照排序值由大到小对类目表中的类目进行排序,选择排序前预设位的类目生成候选类目序列。In some optional implementations of this embodiment, the above-mentioned sorting unit 601 is further configured to: according to the preset weight of the last access time and the weight of the number of visits, the most recent access time and access time of the categories in the above category table The number of times weighted summation is used to determine the sorting value of the categories in the above category table; the categories in the category table are sorted according to the sorting value from large to small, and the categories that are preset before sorting are selected to generate a candidate category sequence .

在本实施例的一些可选的实现方式中,上述调整单元602可以进一步被配置成:响应于确定上述用户的最近访问类目位于上述候选类目序列中,将上述用户的最近访问类目调整至上述候选类目序列的首位。In some optional implementations of this embodiment, the adjusting unit 602 may be further configured to: in response to determining that the most recently visited category of the above-mentioned user is located in the above-mentioned candidate category sequence, adjust the above-mentioned user's most recently visited category to the top of the above candidate category sequence.

在本实施例的一些可选的实现方式中,上述调整单元602还可以进一步被配置成:响应于确定上述用户的最近访问类目不位于上述候选类目序列中,将上述用户的最近访问类目插入至上述候选类目序列的首位;响应于在首位插入上述用户的最近访问类目后的候选类目序列的长度超过上述候选类目序列的最大长度,将在首位插入上述用户的最近访问类目后的候选类目序列中排序末位的类目删除。In some optional implementations of this embodiment, the adjusting unit 602 may be further configured to: in response to determining that the most recently visited category of the above-mentioned user is not located in the above-mentioned candidate category sequence, adjust the above-mentioned user's most recently visited category In response to the length of the candidate category sequence after inserting the user's recently visited category at the first position exceeds the maximum length of the candidate category sequence, the user's most recent visit will be inserted at the first position. The last category in the candidate category sequence after the category is deleted.

在本实施例的一些可选的实现方式中,上述用于呈现类目信息的装置可以设置于客户端,能够克服服务端的装置收集用户信息有限而导致分类的排序信息还是不够实时和准确的缺点。设置于客户端的优点还包括避免导致用户隐私泄露,从而可以获取用户更多的信息(例如浏览记录、购物记录),而且在客户端可以实时获取这些信息,解决了流量、隐私,特别是数据实效性等一系列的问题。In some optional implementations of this embodiment, the above-mentioned apparatus for presenting category information may be set on the client, which can overcome the disadvantage that the sorting information of the classification is not real-time and accurate due to the limited collection of user information by the apparatus at the server. . The advantages of setting it on the client side also include avoiding leakage of user privacy, so that more user information (such as browsing records and shopping records) can be obtained, and these information can be obtained in real time on the client side, which solves the problem of traffic, privacy, and especially data effectiveness. gender and other issues.

在本实施例的一些可选的实现方式中,上述预先创建的类目表是通过以下创建步骤得到的:创建类目表,类目表中的每一条数据包括类目标识、访问次数、最近访问时间;确定用户访问的物品信息所属类目的类目标识,响应于确定上述类目表中存在用户访问的物品信息所属类目的类目标识,将上述类目表中上述用户访问的物品信息所属类目的类目标识对应的访问次数加一,将上述类目表中上述用户访问的物品信息所属类目的类目标识对应的最近访问时间更新为上述用户访问上述物品信息的时间。In some optional implementations of this embodiment, the above-mentioned pre-created category table is obtained through the following creation steps: creating a category table, and each piece of data in the category table includes category identification, number of visits, recent Access time; determine the category identifier of the category to which the item information accessed by the user belongs, and in response to determining that there is a category identifier of the category to which the item information accessed by the user belongs in the category table, the items accessed by the user in the category table The number of visits corresponding to the category identifier of the category to which the information belongs is incremented by one, and the most recent access time corresponding to the category identifier of the category to which the item information accessed by the user in the category table belongs is updated to the time when the user accesses the item information.

在本实施例的一些可选的实现方式中,上述创建步骤还包括:响应于确定上述类目表中不存在上述用户访问的物品信息所属类目的类目标识,将上述用户访问的物品信息所属类目的类目标识添加到上述类目表中,将上述用户访问的物品信息所属类目的类目标识的访问次数置为1,将上述用户访问的物品信息所属类目的类目标识对应的最近访问时间置为上述用户访问上述物品信息的时间并存储上述添加操作后的类目表。In some optional implementations of this embodiment, the above-mentioned creating step further includes: in response to determining that there is no category identifier of the category to which the above-mentioned user-accessed item information belongs in the above-mentioned category table, the above-mentioned user-accessed item information The category identifier of the category to which it belongs is added to the above category table, the number of visits of the category identifier of the category to which the item information accessed by the user belongs is set to 1, and the category identifier of the category to which the item information accessed by the user belongs is set. The corresponding latest access time is set as the time when the user accesses the item information and the category table after the adding operation is stored.

在本实施例的一些可选的实现方式中,上述创建步骤还可以包括:将上述类目表中的最近访问时间早于预设时间的类目标识对应的访问次数和最近访问时间置零。In some optional implementations of this embodiment, the above-mentioned creating step may further include: zeroing the number of visits and the most recent visit time corresponding to the category identifier whose most recent access time is earlier than the preset time in the above-mentioned category table.

本申请的上述实施例提供的装置,排序单元601被配置成根据用户对预先创建的类目表中的类目的最近访问时间和访问次数,对上述类目表中的类目进行排序,生成候选类目序列;调整单元602被配置成根据上述用户的最近访问类目调整上述候选类目序列中的类目的排序;呈现单元603被配置成按照调整后的类目的排序呈现类目信息。本申请的上述实施例提供的装置根据用户的最近访问类目,对类目排序后进行呈现,实现了针对不同的用户差异化地呈现类目信息,呈现类目的顺序更符合用户的需求,提高了呈现类目信息的效率。。In the apparatus provided by the above-mentioned embodiments of the present application, the sorting unit 601 is configured to sort the categories in the above-mentioned category table according to the latest access time and the number of visits to the categories in the pre-created category table by the user, and generate A sequence of candidate categories; the adjustment unit 602 is configured to adjust the ranking of the categories in the sequence of candidate categories according to the categories recently accessed by the users; the presentation unit 603 is configured to present category information according to the adjusted ranking of categories . The device provided by the above-mentioned embodiments of the present application sorts and presents the categories according to the categories recently accessed by the user, thereby realizing the differentiated presentation of category information for different users, and the order of presenting categories is more in line with the needs of users. The efficiency of presenting category information is improved. .

下面参考图7,其示出了适于用来实现本公开的实施例的电子设备(例如图1中的服务器)700的结构示意图。图7示出的电子设备仅仅是一个示例,不应对本公开的实施例的功能和使用范围带来任何限制。Referring next to FIG. 7 , it shows a schematic structural diagram of an electronic device (eg, the server in FIG. 1 ) 700 suitable for implementing embodiments of the present disclosure. The electronic device shown in FIG. 7 is only an example, and should not impose any limitation on the function and scope of use of the embodiments of the present disclosure.

如图7所示,电子设备700可以包括处理装置(例如中央处理单元(CPU)、图形处理器等)701,其可以根据存储在只读存储器(ROM)702中的程序或者从存储装置708加载到随机访问存储器(RAM)703中的程序而执行各种适当的动作和处理。在RAM 703中,还存储有电子设备700操作所需的各种程序和数据。处理装置701、ROM 702以及RAM 703通过总线704彼此相连。输入/输出(I/O)接口705也连接至总线704。As shown in FIG. 7 , an electronic device 700 may include a processing device (eg, a central processing unit (CPU), a graphics processor, etc.) 701 that may be loaded according to a program stored in a read only memory (ROM) 702 or from a storage device 708 A program in random access memory (RAM) 703 executes various appropriate actions and processes. In the RAM 703, various programs and data necessary for the operation of the electronic device 700 are also stored. The processing device 701 , the ROM 702 , and the RAM 703 are connected to each other through a bus 704 . An input/output (I/O) interface 705 is also connected to bus 704 .

通常,以下装置可以连接至I/O接口705:包括例如触摸屏、触摸板、键盘、鼠标、摄像头、麦克风、加速度计、陀螺仪等的输入装置706;包括例如液晶显示器(LCD)、扬声器、振动器等的输出装置707;包括例如磁带、硬盘等的存储装置708;以及通信装置709。通信装置709可以允许电子设备700与其他设备进行无线或有线通信以交换数据。虽然图7示出了具有各种装置的电子设备700,但是应理解的是,并不要求实施或具备所有示出的装置。可以替代地实施或具备更多或更少的装置。图7中示出的每个方框可以代表一个装置,也可以根据需要代表多个装置。Typically, the following devices can be connected to the I/O interface 705: input devices 706 including, for example, a touch screen, touchpad, keyboard, mouse, camera, microphone, accelerometer, gyroscope, etc.; including, for example, a liquid crystal display (LCD), speakers, vibration An output device 707 of a computer, etc.; a storage device 708 including, for example, a magnetic tape, a hard disk, etc.; and a communication device 709. Communication means 709 may allow electronic device 700 to communicate wirelessly or by wire with other devices to exchange data. Although FIG. 7 shows an electronic device 700 having various means, it should be understood that not all of the illustrated means are required to be implemented or provided. More or fewer devices may alternatively be implemented or provided. Each block shown in FIG. 7 can represent one device, and can also represent multiple devices as required.

特别地,根据本公开的实施例,上文参考流程图描述的过程可以被实现为计算机软件程序。例如,本公开的实施例包括一种计算机程序产品,其包括承载在计算机可读介质上的计算机程序,该计算机程序包含用于执行流程图所示的方法的程序代码。在这样的实施例中,该计算机程序可以通过通信装置709从网络上被下载和安装,或者从存储装置708被安装,或者从ROM 702被安装。在该计算机程序被处理装置701执行时,执行本公开的实施例的方法中限定的上述功能。需要说明的是,本公开的实施例的计算机可读介质可以是计算机可读信号介质或者计算机可读存储介质或者是上述两者的任意组合。计算机可读存储介质例如可以是——但不限于——电、磁、光、电磁、红外线、或半导体的系统、装置或器件,或者任意以上的组合。计算机可读存储介质的更具体的例子可以包括但不限于:具有一个或多个导线的电连接、便携式计算机磁盘、硬盘、随机访问存储器(RAM)、只读存储器(ROM)、可擦式可编程只读存储器(EPROM或闪存)、光纤、便携式紧凑磁盘只读存储器(CD-ROM)、光存储器件、磁存储器件、或者上述的任意合适的组合。在本公开的实施例中,计算机可读存储介质可以是任何包含或存储程序的有形介质,该程序可以被指令执行系统、装置或者器件使用或者与其结合使用。而在本公开的实施例中,计算机可读信号介质可以包括在基带中或者作为载波一部分传播的数据信号,其中承载了计算机可读的程序代码。这种传播的数据信号可以采用多种形式,包括但不限于电磁信号、光信号或上述的任意合适的组合。计算机可读信号介质还可以是计算机可读存储介质以外的任何计算机可读介质,该计算机可读信号介质可以发送、传播或者传输用于由指令执行系统、装置或者器件使用或者与其结合使用的程序。计算机可读介质上包含的程序代码可以用任何适当的介质传输,包括但不限于:电线、光缆、RF(射频)等等,或者上述的任意合适的组合。In particular, according to embodiments of the present disclosure, the processes described above with reference to the flowcharts may be implemented as computer software programs. For example, embodiments of the present disclosure include a computer program product comprising a computer program carried on a computer-readable medium, the computer program containing program code for performing the method illustrated in the flowchart. In such an embodiment, the computer program may be downloaded and installed from the network via the communication device 709 , or from the storage device 708 , or from the ROM 702 . When the computer program is executed by the processing device 701, the above-described functions defined in the methods of the embodiments of the present disclosure are executed. It should be noted that the computer-readable medium of the embodiments of the present disclosure may be a computer-readable signal medium or a computer-readable storage medium, or any combination of the above two. The computer-readable storage medium can be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus or device, or a combination of any of the above. More specific examples of computer readable storage media may include, but are not limited to, electrical connections with one or more wires, portable computer disks, hard disks, random access memory (RAM), read only memory (ROM), erasable Programmable read only memory (EPROM or flash memory), fiber optics, portable compact disk read only memory (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination of the foregoing. In embodiments of the present disclosure, a computer-readable storage medium may be any tangible medium that contains or stores a program that can be used by or in conjunction with an instruction execution system, apparatus, or device. Rather, in embodiments of the present disclosure, a computer-readable signal medium may include a data signal in baseband or propagated as part of a carrier wave, carrying computer-readable program code therein. Such propagated data signals may take a variety of forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the foregoing. A computer-readable signal medium can also be any computer-readable medium other than a computer-readable storage medium that can transmit, propagate, or transport the program for use by or in connection with the instruction execution system, apparatus, or device . Program code embodied on a computer readable medium may be transmitted using any suitable medium including, but not limited to, electrical wire, optical fiber cable, RF (radio frequency), etc., or any suitable combination of the foregoing.

上述计算机可读介质可以是上述电子设备中所包含的;也可以是单独存在,而未装配入该电子设备中。上述计算机可读介质承载有一个或者多个程序,当上述一个或者多个程序被该电子设备执行时,使得该电子设备:根据用户对预先创建的类目表中的类目的最近访问时间和访问次数,对上述类目表中的类目进行排序,生成候选类目序列;根据上述用户的最近访问类目调整上述候选类目序列中的类目的排序;按照调整后的类目的排序呈现类目信息。The above-mentioned computer-readable medium may be included in the above-mentioned electronic device; or may exist alone without being assembled into the electronic device. The above-mentioned computer-readable medium carries one or more programs, and when the above-mentioned one or more programs are executed by the electronic device, the electronic device: The number of visits, sort the categories in the above category table, and generate a sequence of candidate categories; adjust the sorting of the categories in the above candidate category sequence according to the categories recently visited by the above-mentioned users; sort according to the adjusted categories Present category information.

可以以一种或多种程序设计语言或其组合来编写用于执行本公开的实施例的操作的计算机程序代码,程序设计语言包括面向对象的程序设计语言—诸如Java、Smalltalk、C++,还包括常规的过程式程序设计语言—诸如“C”语言或类似的程序设计语言。程序代码可以完全地在用户计算机上执行、部分地在用户计算机上执行、作为一个独立的软件包执行、部分在用户计算机上部分在远程计算机上执行、或者完全在远程计算机或服务器上执行。在涉及远程计算机的情形中,远程计算机可以通过任意种类的网络——包括局域网(LAN)或广域网(WAN)—连接到用户计算机,或者,可以连接到外部计算机(例如利用因特网服务提供商来通过因特网连接)。Computer program code for carrying out operations of embodiments of the present disclosure may be written in one or more programming languages, including object-oriented programming languages—such as Java, Smalltalk, C++, and also A conventional procedural programming language - such as the "C" language or similar programming language. The program code may execute entirely on the user's computer, partly on the user's computer, as a stand-alone software package, partly on the user's computer and partly on a remote computer, or entirely on the remote computer or server. In the case of a remote computer, the remote computer may be connected to the user's computer through any kind of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computer (eg, using an Internet service provider through Internet connection).

附图中的流程图和框图,图示了按照本公开各种实施例的系统、方法和计算机程序产品的可能实现的体系架构、功能和操作。在这点上,流程图或框图中的每个方框可以代表一个模块、程序段、或代码的一部分,该模块、程序段、或代码的一部分包含一个或多个用于实现规定的逻辑功能的可执行指令。也应当注意,在有些作为替换的实现中,方框中所标注的功能也可以以不同于附图中所标注的顺序发生。例如,两个接连地表示的方框实际上可以基本并行地执行,它们有时也可以按相反的顺序执行,这依所涉及的功能而定。也要注意的是,框图和/或流程图中的每个方框、以及框图和/或流程图中的方框的组合,可以用执行规定的功能或操作的专用的基于硬件的系统来实现,或者可以用专用硬件与计算机指令的组合来实现。The flowchart and block diagrams in the Figures illustrate the architecture, functionality, and operation of possible implementations of systems, methods and computer program products according to various embodiments of the present disclosure. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of code that contains one or more logical functions for implementing the specified functions executable instructions. It should also be noted that, in some alternative implementations, the functions noted in the blocks may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It is also noted that each block of the block diagrams and/or flowchart illustrations, and combinations of blocks in the block diagrams and/or flowchart illustrations, can be implemented in dedicated hardware-based systems that perform the specified functions or operations , or can be implemented in a combination of dedicated hardware and computer instructions.

以上描述仅为本申请的较佳实施例以及对所运用技术原理的说明。本领域技术人员应当理解,本申请中所涉及的发明范围,并不限于上述技术特征的特定组合而成的技术方案,同时也应涵盖在不脱离上述发明构思的情况下,由上述技术特征或其等同特征进行任意组合而形成的其它技术方案。例如上述特征与本申请中公开的(但不限于)具有类似功能的技术特征进行互相替换而形成的技术方案。The above description is only a preferred embodiment of the present application and an illustration of the applied technical principles. Those skilled in the art should understand that the scope of the invention involved in this application is not limited to the technical solution formed by the specific combination of the above technical features, and should also cover the above technical features or Other technical solutions formed by any combination of its equivalent features. For example, a technical solution is formed by replacing the above-mentioned features with the technical features disclosed in this application (but not limited to) with similar functions.

Claims (18)

1.一种用于呈现类目信息的方法,包括:1. A method for presenting category information, comprising: 根据用户对预先创建的类目表中的类目的最近访问时间和访问次数,对所述类目表中的类目进行排序,生成候选类目序列;Sort the categories in the category table according to the latest access time and the number of visits of the categories in the pre-created category table by the user, and generate a candidate category sequence; 根据所述用户的最近访问类目调整所述候选类目序列中的类目的排序;Adjust the ranking of categories in the candidate category sequence according to the user's most recently visited categories; 按照调整后的类目的排序呈现类目信息。The category information is presented according to the order of the adjusted categories. 2.根据权利要求1所述的方法,其中,所述根据用户对预先创建的类目表中的类目的最近访问时间和访问次数,对所述类目表中的类目进行排序,生成候选类目序列,包括:2. The method according to claim 1, wherein, according to the latest access time and the number of visits of the categories in the pre-created category table by the user, the categories in the category table are sorted to generate A sequence of candidate categories, including: 根据预设的最近访问时间权重和访问次数权重,对所述类目表中的类目的最近访问时间和访问次数加权求和,确定所述类目表中的类目的排序值;According to the preset weight of recent access time and the weight of the number of visits, weighted summation of the most recent access time and the number of visits of the categories in the category table, to determine the ranking value of the categories in the category table; 按照排序值由大到小对类目表中的类目进行排序,选择排序前预设位的类目生成候选类目序列。Sort the categories in the category table according to the sorting value in descending order, and select the categories preset before sorting to generate the candidate category sequence. 3.根据权利要求2所述的方法,其中,所述根据所述用户的最近访问类目调整所述候选类目序列中的类目的排序,包括:3. The method according to claim 2, wherein the adjusting the ranking of categories in the sequence of candidate categories according to the most recently visited categories of the user comprises: 响应于确定所述用户的最近访问类目位于所述候选类目序列中,将所述用户的最近访问类目调整至所述候选类目序列的首位。In response to determining that the user's most recently visited category is in the candidate category sequence, the user's recently visited category is adjusted to the top of the candidate category sequence. 4.根据权利要求2或3所述的方法,其中,所述根据所述用户的最近访问类目调整所述候选类目序列中的类目的排序,还包括:4. The method according to claim 2 or 3, wherein the adjusting the ranking of categories in the candidate category sequence according to the user's recently visited categories further comprises: 响应于确定所述用户的最近访问类目不位于所述候选类目序列中,将所述用户的最近访问类目插入至所述候选类目序列的首位;In response to determining that the user's recently visited category is not located in the candidate category sequence, inserting the user's recently visited category into the first position of the candidate category sequence; 响应于在首位插入所述用户的最近访问类目后的候选类目序列的长度超过所述候选类目序列的最大长度,将在首位插入所述用户的最近访问类目后的候选类目序列中排序末位的类目删除。In response to the length of the candidate category sequence after the user's most recently visited category inserted in the first position exceeds the maximum length of the candidate category sequence, the candidate category sequence after the user's recently visited category will be inserted in the first position The category at the bottom of the sorting order is deleted. 5.根据权利要求1所述的方法,其中,所述方法应用于客户端。5. The method of claim 1, wherein the method is applied to a client. 6.根据权利要求1所述的方法,其中,所述预先创建的类目表是通过以下创建步骤得到的:6. The method of claim 1, wherein the pre-created category table is obtained by the following steps of creating: 创建类目表,类目表中的每一条数据包括类目标识、访问次数、最近访问时间;Create a category table, each piece of data in the category table includes category identification, number of visits, and recent visit time; 确定用户访问的物品信息所属类目的类目标识,响应于确定所述类目表中存在用户访问的物品信息所属类目的类目标识,将所述类目表中所述用户访问的物品信息所属类目的类目标识对应的访问次数加一,将所述类目表中所述用户访问的物品信息所属类目的类目标识对应的最近访问时间更新为所述用户访问所述物品信息的时间。Determine the category identifier of the category to which the item information accessed by the user belongs, and in response to determining that there is a category identifier of the category to which the item information accessed by the user belongs in the category table, classify the item accessed by the user in the category table The number of visits corresponding to the category identifier of the category to which the information belongs is incremented by one, and the latest access time corresponding to the category identifier of the category to which the item information accessed by the user in the category table belongs is updated as the user accessing the item information time. 7.根据权利要求6所述的方法,其中,所述创建步骤还包括:7. The method of claim 6, wherein the creating step further comprises: 响应于确定所述类目表中不存在所述用户访问的物品信息所属类目的类目标识,将所述用户访问的物品信息所属类目的类目标识添加到所述类目表中,将所述用户访问的物品信息所属类目的类目标识的访问次数置为1,将所述用户访问的物品信息所属类目的类目标识对应的最近访问时间置为所述用户访问所述物品信息的时间并存储所述添加操作后的类目表。In response to determining that the category identifier of the category to which the item information accessed by the user belongs does not exist in the category table, adding the category identifier of the category to which the item information accessed by the user belongs to the category table, Set the number of visits of the category ID of the category to which the item information accessed by the user belongs to 1, and set the latest access time corresponding to the category ID of the category to which the item information accessed by the user belongs as the user accessing the item. The time of item information and the category table after the adding operation are stored. 8.根据权利要求6所述的方法,其中,所述创建步骤还包括:8. The method of claim 6, wherein the creating step further comprises: 将所述类目表中的最近访问时间早于预设时间的类目标识对应的访问次数和最近访问时间置零。The number of visits and the most recent visit time corresponding to the category identifier whose most recent access time is earlier than the preset time in the category table is set to zero. 9.一种用于呈现类目信息的装置,包括:9. An apparatus for presenting category information, comprising: 排序单元,被配置成根据用户对预先创建的类目表中的类目的最近访问时间和访问次数,对所述类目表中的类目进行排序,生成候选类目序列;a sorting unit, configured to sort the categories in the category table according to the latest access time and the number of visits of the categories in the pre-created category table by the user to generate a sequence of candidate categories; 调整单元,被配置成根据所述用户的最近访问类目调整所述候选类目序列中的类目的排序;an adjustment unit configured to adjust the ranking of categories in the candidate category sequence according to the user's most recently visited categories; 呈现单元,被配置成按照调整后的类目的排序呈现类目信息。The presentation unit is configured to present category information according to the adjusted order of categories. 10.根据权利要求9所述的装置,其中,所述排序单元进一步被配置成:10. The apparatus of claim 9, wherein the sorting unit is further configured to: 根据预设的最近访问时间权重和访问次数权重,对所述类目表中的类目的最近访问时间和访问次数加权求和,确定所述类目表中的类目的排序值;According to the preset weight of recent access time and the weight of the number of visits, weighted summation of the most recent access time and the number of visits of the categories in the category table, to determine the ranking value of the categories in the category table; 按照排序值由大到小对类目表中的类目进行排序,选择排序前预设位的类目生成候选类目序列。Sort the categories in the category table according to the sorting value in descending order, and select the categories preset before sorting to generate the candidate category sequence. 11.根据权利要求10所述的装置,其中,所述调整单元进一步被配置成:11. The apparatus of claim 10, wherein the adjustment unit is further configured to: 响应于确定所述用户的最近访问类目位于所述候选类目序列中,将所述用户的最近访问类目调整至所述候选类目序列的首位。In response to determining that the user's most recently visited category is in the candidate category sequence, the user's recently visited category is adjusted to the top of the candidate category sequence. 12.根据权利要求10或11所述的装置,其中,所述调整单元进一步被配置成:12. The apparatus of claim 10 or 11, wherein the adjustment unit is further configured to: 响应于确定所述用户的最近访问类目不位于所述候选类目序列中,将所述用户的最近访问类目插入至所述候选类目序列的首位;In response to determining that the user's recently visited category is not located in the candidate category sequence, inserting the user's recently visited category into the first position of the candidate category sequence; 响应于在首位插入所述用户的最近访问类目后的候选类目序列的长度超过所述候选类目序列的最大长度,将在首位插入所述用户的最近访问类目后的候选类目序列中排序末位的类目删除。In response to the length of the candidate category sequence after the user's most recently visited category inserted in the first position exceeds the maximum length of the candidate category sequence, the candidate category sequence after the user's recently visited category will be inserted in the first position The category at the bottom of the sorting order is deleted. 13.根据权利要求9所述的装置,其中,所述装置设置于客户端。13. The apparatus of claim 9, wherein the apparatus is provided at a client. 14.根据权利要求9所述的装置,其中,所述预先创建的类目表是通过以下创建步骤得到的:14. The apparatus of claim 9, wherein the pre-created category table is obtained by the following steps of creating: 创建类目表,类目表中的每一条数据包括类目标识、访问次数、最近访问时间;Create a category table, each piece of data in the category table includes category identification, number of visits, and recent visit time; 确定用户访问的物品信息所属类目的类目标识,响应于确定所述类目表中存在用户访问的物品信息所属类目的类目标识,将所述类目表中所述用户访问的物品信息所属类目的类目标识对应的访问次数加一,将所述类目表中所述用户访问的物品信息所属类目的类目标识对应的最近访问时间更新为所述用户访问所述物品信息的时间。Determine the category identifier of the category to which the item information accessed by the user belongs, and in response to determining that there is a category identifier of the category to which the item information accessed by the user belongs in the category table, classify the item accessed by the user in the category table The number of visits corresponding to the category identifier of the category to which the information belongs is incremented by one, and the latest access time corresponding to the category identifier of the category to which the item information accessed by the user in the category table belongs is updated as the user accessing the item information time. 15.根据权利要求14所述的装置,其中,所述创建步骤还包括:15. The apparatus of claim 14, wherein the creating step further comprises: 响应于确定所述类目表中不存在所述用户访问的物品信息所属类目的类目标识,将所述用户访问的物品信息所属类目的类目标识添加到所述类目表中,将所述用户访问的物品信息所属类目的类目标识的访问次数置为1,将所述用户访问的物品信息所属类目的类目标识对应的最近访问时间置为所述用户访问所述物品信息的时间并存储所述添加操作后的类目表。In response to determining that the category identifier of the category to which the item information accessed by the user belongs does not exist in the category table, adding the category identifier of the category to which the item information accessed by the user belongs to the category table, Set the number of visits of the category ID of the category to which the item information accessed by the user belongs to 1, and set the latest access time corresponding to the category ID of the category to which the item information accessed by the user belongs as the user accessing the item. The time of item information and the category table after the adding operation are stored. 16.根据权利要求14所述的装置,其中,所述创建步骤还包括:16. The apparatus of claim 14, wherein the creating step further comprises: 将所述类目表中的最近访问时间早于预设时间的类目标识对应的访问次数和最近访问时间置零。The number of visits and the most recent visit time corresponding to the category identifier whose most recent access time is earlier than the preset time in the category table is set to zero. 17.一种电子设备,包括:17. An electronic device comprising: 一个或多个处理器;one or more processors; 存储装置,用于存储一个或多个程序,storage means for storing one or more programs, 当所述一个或多个程序被所述一个或多个处理器执行,使得所述一个或多个处理器实现如权利要求1-8中任一所述的方法。The one or more programs, when executed by the one or more processors, cause the one or more processors to implement the method of any one of claims 1-8. 18.一种计算机可读介质,其上存储有计算机程序,其中,所述程序被处理器执行时实现如权利要求1-8中任一所述的方法。18. A computer-readable medium having stored thereon a computer program, wherein the program, when executed by a processor, implements the method of any one of claims 1-8.
CN201910434577.6A 2019-05-23 2019-05-23 Method and apparatus for presenting category information Pending CN111984854A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910434577.6A CN111984854A (en) 2019-05-23 2019-05-23 Method and apparatus for presenting category information

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910434577.6A CN111984854A (en) 2019-05-23 2019-05-23 Method and apparatus for presenting category information

Publications (1)

Publication Number Publication Date
CN111984854A true CN111984854A (en) 2020-11-24

Family

ID=73436550

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910434577.6A Pending CN111984854A (en) 2019-05-23 2019-05-23 Method and apparatus for presenting category information

Country Status (1)

Country Link
CN (1) CN111984854A (en)

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102682005A (en) * 2011-03-10 2012-09-19 阿里巴巴集团控股有限公司 Method and device for determining preference categories
CN103795788A (en) * 2014-01-20 2014-05-14 中国建设银行股份有限公司 Load balancing method of instant messaging server and load balancing server
CN105528392A (en) * 2015-11-27 2016-04-27 网易传媒科技(北京)有限公司 Class label ordering method and apparatus

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102682005A (en) * 2011-03-10 2012-09-19 阿里巴巴集团控股有限公司 Method and device for determining preference categories
CN103795788A (en) * 2014-01-20 2014-05-14 中国建设银行股份有限公司 Load balancing method of instant messaging server and load balancing server
CN105528392A (en) * 2015-11-27 2016-04-27 网易传媒科技(北京)有限公司 Class label ordering method and apparatus

Similar Documents

Publication Publication Date Title
US10521404B2 (en) Data transformations with metadata
US11194882B1 (en) Behavior based optimization for content presentation
US9595053B1 (en) Product recommendation using sentiment and semantic analysis
US20240370405A1 (en) Lineage data for data records
CN104516910B (en) The content recommendation in client server environment
US8224823B1 (en) Browsing history restoration
CN108965389B (en) Method for displaying information
US20190347287A1 (en) Method for screening and injection of media content based on user preferences
US20170330239A1 (en) Methods and systems for near real-time lookalike audience expansion in ads targeting
US9594540B1 (en) Techniques for providing item information by expanding item facets
CN111291765A (en) Method and device for determining similar pictures
US20180005131A1 (en) Automatic Social Media Content Timeline Summarization Method and Apparatus
CN105488205B (en) Page generation method and device
CN110851710A (en) Novel recommendation method and device
US20240168605A1 (en) Text input method and apparatus, and electronic device and storage medium
CN107870984A (en) The method and apparatus for identifying the intention of search term
CN108170731A (en) Data processing method, device, computer storage media and server
WO2023241332A1 (en) Snippet information generation method and apparatus, search result display method and apparatus, device, and medium
US8515931B1 (en) Techniques for search optimization
KR102712013B1 (en) Method and device for transmitting information
CN108540508B (en) Method, device and equipment for pushing information
US20120203865A1 (en) Apparatus and methods for providing behavioral retargeting of content from partner websites
US20200081930A1 (en) Entity-based search system using user engagement
CN112449217B (en) Method and device for pushing video, electronic equipment and computer readable medium
US11307897B2 (en) Resource pre-fetch using age threshold

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination