Summary of the invention
The present invention is directed to overcome at least one defect (deficiency) of the above-mentioned prior art, a kind of user behavior analysis side is provided
Method and resource recommendation method based on the analysis method, can well analyze user behavior, be generated according to analysis
Decision tree can reduce the difficulty to new user behavior analysis, excavate the Fuzzy Demand of new user.
The technical solution adopted by the present invention is that:
A kind of user behavior analysis method, comprising:
Oriented behavior figure is generated according to the behavioral data of certain user;
The behavior side right weight of the oriented behavior figure is calculated, active path is extracted;
Behavioral data is divided into focal need and Fuzzy Demand, the user characteristics of focal need corresponding resource characteristic and the user
Between mapping relations formed focal need feature, between the corresponding resource characteristic of Fuzzy Demand and the user characteristics of the user
Mapping relations form Fuzzy Demand feature, and the focal need feature of multiple users is put into user demand relationship library;
Clustering is carried out to the Fuzzy Demand feature of multiple similar users, obtains similar users demand characteristic collection and/or to more
The similar Fuzzy Demand feature of a user carries out clustering, obtains similar demands user characteristics collection, and similar users demand is special
Collection and/or similar demands user characteristics collection are put into user demand relationship library;
Resource Role frame is generated according to oriented behavior figure;
Decision tree is generated according to Resource Role frame, user demand relationship library.
Multiple user behavior datas are sampled, the behavioral data sampled is divided into focal need and Fuzzy Demand,
The Resource Role frame that can be generated after focal need and Fuzzy Demand are analyzed and handled respectively, user demand relationship
Library, and construct decision tree.Demand by decision tree to user is analyzed, and can reduce the difficulty of demand analysis, sufficiently
The Fuzzy Demand of user is excavated, to recommend the resource and service that more meet user demand for user.
Further, oriented behavior figure is generated according to the behavioral data of certain user, specifically included:
Transaction types, action type, time of the act length, resource characteristic when recording certain user behavior;
Propagating Tree is formed as root node, action type as child node using transaction types;
Born of the same parents pond is established in child node according to time of the act length, resource characteristic is as the cellular in born of the same parents pond;
Oriented behavior figure is generated using born of the same parents pond as side.
Further, oriented behavior figure is generated according to the behavioral data of certain user, specifically included:
According to the behavioral data of certain user, judge the user for focal need user or Fuzzy Demand user;
If the user is focal need user, oriented behavior figure is generated according to the behavioral data of the user;
If the user is Fuzzy Demand user, according to the behavioral data of the behavioral data of the user and the similar users of the user
Generate oriented behavior figure.
When recording the behavioral data of user, can according to the demand of user intention degree it is different and carry out different records,
Thus oriented behavior figure generated, can allow user demand relationship library, Resource Role frame and the decision tree being subsequently generated
The behavior of user can preferably be analyzed.
Further, according to the behavioral data of certain user, judge that the user uses for focal need user or Fuzzy Demand
Family specifically includes:
According to the behavior similarity and/or the user behavior between the behavioral data structure and user behavior logical model of user
Resource similarity between Resource Role and/or the user in resource characteristic in data and built in advance Resource Role feature database
User characteristics and built in advance user role feature database in user role between user's similarity, judge the user for orientation need
Ask user or Fuzzy Demand user.
Further, the behavior side right weight of the oriented behavior figure is calculated, active path is extracted, specifically includes:
Clustering is carried out to the behavioral data in time scale, calculates the time weighting of the oriented behavior figure, is formed
Time behavior datagram;
Clustering is carried out to the behavioral data on space scale, calculates the space weight of the oriented behavior figure, is formed
Spatial behavior datagram;
According to the behavior side right weight of oriented behavior figure described in time weighting and space weight calculation, difference extraction time behavioral data
The active path of figure and spatial behavior datagram.
Further, behavioral data is divided into focal need and Fuzzy Demand, specifically included:
The shortest path of time behavior datagram and spatial behavior datagram is merged to obtain user's direct demand feature;
The circuit crosspoint in active path is analyzed, loop-free paths are extracted, the resource characteristic of loop-free paths and user is straight
It connects demand characteristic and carries out similarity analysis, determine that the corresponding behavioral data of loop-free paths is orientation according to similarity analysis result
Demand or Fuzzy Demand.
Further, Resource Role frame is generated according to oriented behavior figure, specifically included:
It extracts weight in oriented behavior figure and is higher than the side of preset value as subgraph a;
Traverse user demand relation library, sieve take subgraph b of the support higher than support threshold;
If the main resource feature of subgraph a is A, the main resource feature of subgraph b is B, calculates the confidence level of A to B and B to A;
The resource characteristic that confidence level is higher than confidence threshold value is filtered out, the resource characteristic filtered out is constituted into Resource Role frame.
Further, decision tree is generated according to Resource Role frame, user demand relationship library, specifically included:
It is ranked up using resource characteristic of the bubbling method to Resource Role frame according to confidence level, is determined using obtained sequence as master
Plan rule;
User demand relationship library conclude and forms aid decision rule;
Decision tree is generated according to main decision rule and aid decision rule.
A kind of resource recommendation method, comprising:
Obtain the Fuzzy Demand feature of user;
According to decision tree as described above, obtain and the highest demand characteristic of the Fuzzy Demand feature degree of correlation and the demand characteristic pair
The Resource Role answered;
Recommend resource to user according to Resource Role.
When user input be Fuzzy Demand when, the demand by decision tree to user is analyzed, and demand can be reduced
The difficulty of analysis sufficiently excavates the Fuzzy Demand of user, to recommend the resource and service that more meet user demand for user.
Further, the method also includes:
User role is obtained according to the user characteristics of user;
Recommend resource to user according to user role and Resource Role.
Compared with prior art, the invention has the benefit that by formulate user behavior data recording mode, according to
Family behavioral data generates oriented behavior figure, and user behavior data is divided into focal need and Fuzzy Demand, forms Resource Role frame
Frame, user demand relationship library simultaneously construct decision tree, reduce the difficulty analyzed new user behavior data, excavate the fuzzy of new user
Demand provides more friendly resource recommendation for user.
Embodiment 1
As shown in Figure 1, the present embodiment provides a kind of user behavior analysis methods, comprising:
A1. oriented behavior figure is generated according to the behavioral data of certain user;
A2. the behavior side right weight of the oriented behavior figure is calculated, active path is extracted;
A3. behavioral data is divided into focal need and Fuzzy Demand, the user of focal need corresponding resource characteristic and the user
Mapping relations between feature form focal need feature, the user characteristics of the corresponding resource characteristic of Fuzzy Demand and the user it
Between mapping relations formed Fuzzy Demand feature, the focal need feature of multiple users is put into user demand relationship library;
A4. clustering is carried out to the Fuzzy Demand features of multiple similar users, obtains similar users demand characteristic collection and/or right
The similar Fuzzy Demand feature of multiple users carries out clustering, similar demands user characteristics collection is obtained, by similar users demand
Feature set and/or similar demands user characteristics collection are put into user demand relationship library;
A5. Resource Role frame is generated according to oriented behavior figure;
A6. decision tree is generated according to Resource Role frame, user demand relationship library.
Multiple user behavior datas are sampled, the behavioral data sampled is divided into focal need and Fuzzy Demand,
The Resource Role frame that can be generated after focal need and Fuzzy Demand are analyzed and handled respectively, user demand relationship
Library, and construct decision tree.Demand by decision tree to user is analyzed, and can reduce the difficulty of demand analysis, sufficiently
The Fuzzy Demand of user is excavated, to recommend the resource and service that more meet user demand for user.
Step A1 is specifically included:
Transaction types, action type, time of the act length, resource characteristic when A11. recording certain user behavior;
A12. Propagating Tree is formed as root node, action type as child node using transaction types;
A13. born of the same parents pond is established in child node according to time of the act length, resource characteristic is as the cellular in born of the same parents pond;
A14. oriented behavior figure is generated using born of the same parents pond as side.
Transaction types are the classification to user behavior property, such as browsing, search, intention confirmation, consulting, transaction etc..
Action type is the classification acted to data interaction in user behavior, and data interaction movement may include whole key mouses
All data informations in operation and action process, such as transaction types are when searching for, and action type can be search row
For keyword input, backspace, deletion, confirmation etc. in the process.
At the beginning of each behavior of user and the end time can be recorded and extrapolate entire behavior it is lasting when
Between, it is denoted as time of the act length, can be in implementation process and buried a little on the tenth skill of each behavior, so that confirmation should
Behavior has terminated.By taking transaction types are search as an example, after user carries out sequence of operations in search box and filtered list,
It buries a little on " confirmation " or " screening " key, is a little triggered when burying, then indicate that current " search " behavior terminates.
Resource characteristic involved in each behavior of user can be recorded and form resource characteristic.
To sum up, the behavioral data of user can be recorded in the form of " transaction code+operation code+data packet+end code ".Right
When entire behavioral data is recorded, Propagating Tree is formed as root node, action type as child node using transaction types, to row
Quantified for time span, is arranged under the child node of Propagating Tree according to time of the act length quantized value for data collection
Resource characteristic is stored in born of the same parents pond, so as to generate the oriented behavior figure using born of the same parents pond as side by born of the same parents pond.
Step A11 is specifically included:
A111. according to the behavioral data of certain user, judge the user for focal need user or Fuzzy Demand user;
If A112. the user is focal need user, oriented behavior figure is generated according to the behavioral data of the user;
If A113. the user is Fuzzy Demand user, according to the row of the behavioral data of the user and the similar users of the user
Oriented behavior figure is generated for data.
When recording the behavioral data of user, can according to the demand of user intention degree it is different and carry out different records.
If the demand intention degree that the behavioral data of user is showed is Fuzzy Demand, also when recording the behavioral data of user
It can recorde the behavioral data of similar users, while oriented behavior figure generated according to the behavioral data of the user and similar users.
Thus oriented behavior figure generated, can allow user demand relationship library, Resource Role frame and the decision tree being subsequently generated
The behavior of user can preferably be analyzed.
Step A111 specifically: similar to the behavior between user behavior logical model according to the behavioral data structure of user
The resource between Resource Role in degree and/or the resource characteristic in the user behavior data and built in advance Resource Role feature database
User's similarity between user role in the user characteristics and built in advance user role feature database of similarity and/or the user,
Judge the user for focal need user or Fuzzy Demand user.
Similarity analysis will be carried out between the behavioral data structure and user behavior logical model of user, the behavior analyzed
Similarity X is user demand intention degree evaluation index I;By the resource characteristic and built in advance Resource Role feature in user behavior data
Similarity analysis is carried out between Resource Role in library, the resource similarity Y analyzed is demand intention degree evaluation index II;It will
Similarity analysis is carried out between user role in the user characteristics and built in advance user role feature database of user, the user analyzed
Similarity Z is user demand intention degree evaluation index III, and user's similarity Z is 1 when can not obtain user role.When
When user demand intention degree evaluation index I and/or II and/or III is lower than lower limit value, then judge the user for Fuzzy Demand use
Family.When being judged simultaneously using three evaluation indexes, the weight order of user demand intention degree evaluation index I, II, III
It is preferred that are as follows: II > I > III.
When judging user for Fuzzy Demand user, then the note of user behavior data is carried out using rule 1 as shown in Figure 1
Record, namely when recording the user behavior data, the similar users behavioral data of the user is also recorded, while according to the user
Oriented behavior figure is generated with the behavioral data of similar users;When judging user for focal need user, then using as shown in Figure 1
Rule 2 carry out the record of user behavior data, namely the behavioral data of the user need to be only recorded, according to the behavior number of the user
According to the oriented behavior figure of generation.
Action logic model can be the empirical model by obtaining after statistics a large number of users behavior;It can also be according to itself
Market survey situation sets the computation rule of Action logic model, and computation rule example is as follows: if user first carries out " search "
Affairs, then " browsing " is carried out, according to user demand relationship library, correlation analysis is carried out to search key, if the degree of correlation is high,
It is set to focal need, if the degree of correlation is low, is set to Fuzzy Demand, continues the subsequent behavior operation of monitoring users, be such as recorded, use
Family in " browsing " affairs when whole general view, the page residence time lower than user be averaged the page residence time when, record appears in
Head and the tail asset data information on the page, during which demand degree keeps " Fuzzy Demand " constant, until user enters resource page
" browsing " affairs are exercised, demand degree is become into " focal need ".In specific implementation, demand degree can be initially set to 0, monitored
In the subsequent behavior of user, according to user behavior degree of upgrading demand.
The built in advance process of Resource Role feature database may is that the Resource Access resource characteristic according to offer;By resource characteristic
It carries out clustering and establishes Resource Role feature database.The resource specifically can be scientific and technological resources, may include instrument, core skill
Art theory, method system etc.;The resource characteristic may include resource name, data-interface, data supplier feature, resource application
The affiliated background of object, resource, resource function performance characteristic etc..The extraction of resource characteristic can be based on resource semantic analysis.
The built in advance process of user role feature database may is that special according to the master data information extraction user of each user
Sign;User characteristics progress clustering is established into user role feature database;The user role feature database includes that user characteristics close
System, class user resources characteristic relation.According to the master data information extraction user role of each user, specifically may is that with
The essential information at family and the resources occupation situation analysis of user obtain user role.
Step A2 is specifically included:
A21. clustering is carried out to the behavioral data in time scale, calculates the time weighting of the oriented behavior figure,
Form time behavior datagram;
A22. clustering is carried out to the behavioral data on space scale, calculates the space weight of the oriented behavior figure,
Form spatial behavior datagram;
A23. the behavior side right weight of the oriented behavior figure according to time weighting and space weight calculation, respectively extraction time behavior
The active path of datagram and spatial behavior datagram.
In step A21, clustering is carried out to the resource characteristic in born of the same parents pond in time scale, is obtained on the unit time
Behavior resource characteristic cluster, character distribution analysis is carried out by clustering on Fourier transform pairs time shaft, obtain feature frequency
Rate distribution, the frequency distribution constitute the weight of time behavior datagram.
In step A22, clustering is carried out to the resource characteristic in born of the same parents pond on space scale, i.e., to global behavior number
Clustering is carried out according to the resource characteristic in sample, several is obtained and clusters, the data in different cluster are carried out in time
Backtracking, obtains distribution of the similar behavioral data in behavior process, is sharpened removal low frequency value to this distribution, obtains high frequency division
Cloth analyzes the time continuity of data characteristics in high frequency distribution, high-frequency characteristic linear distribution value is obtained, according to linear phase
Pass value obtains the distribution of the behavior resource degree of correlation, in this, as the weight of spatial behavior datagram.
It is specific according to the behavior side right of oriented behavior figure described in time weighting and space weight calculation weight in step A23
Are as follows: firstly, the resource characteristic in user behavior data is classified, often according to resources domain and the user characteristics of user
Class resource characteristic has corresponding weight, and the identical resource characteristic of statistics transaction types divides resource characteristic according to weight
Grade, obtains each weight resource characteristic data volume, is overlapped time of the act length, data volume and weight to obtain user behavior
The basic specific gravity of resource requirement;Secondly, counting to the resource characteristic in user behavior data, data characteristics is extracted, according to money
Source demand is weighted than log-log according to feature substantially, the data characteristics probability distribution curve after being weighted, to distributing line into
Row sharpens and obtains the behavior side right weight of user behavior core demand weight namely oriented behavior figure.
Step A3 is specifically included:
A31. the shortest path of time behavior datagram and spatial behavior datagram is merged to obtain user's direct demand feature;
A32. the circuit crosspoint in active path is analyzed, loop-free paths are extracted, the side that born of the same parents pond is greater than threshold value is extracted, will be taken out
The corresponding resource characteristic in the side taken and user's direct demand feature carry out similarity analysis, and being determined according to similarity analysis result should
The corresponding behavioral data in side is focal need or Fuzzy Demand.
The specific implementation process of step A32 may is that the circuit crosspoint in analysis active path, extract without circuit road
Diameter extracts the biggish side in born of the same parents pond, counts the weight on the side, if the weight of this edge is lower than whole weight equal value, transfers this
The resource characteristic and user's direct demand feature are carried out similarity analysis and obtain similarity, by phase by the corresponding resource characteristic in side
The behavioral data like corresponding to side of the degree lower than mean value is classified as Fuzzy Demand, and similarity is higher than behavioral data corresponding to the side of mean value
It is classified as focal need.
In step A4, clustering is carried out to the Fuzzy Demand feature of multiple similar users, it is special to obtain similar users demand
Collection, specifically includes:
A41. in the oriented behavior figure generated according to similar users behavioral data, description similar users direct demand feature is obtained
Shortest path in weight be higher than weight threshold side as subgraph, calculate the support of subgraph;
A42., support is higher than to the resource characteristic in the subgraph of support threshold as similar users demand characteristic, is constituted similar
User demand feature set.
Weight threshold can refer to weight equal value;Support threshold can be support mean value.
Step A5 is specifically included:
A51. it extracts weight in oriented behavior figure and is higher than the side of preset value as subgraph a;
A52. traverse user demand relation library, sieve take subgraph b of the support higher than support threshold;
A53. the main resource feature of subgraph a is set as A, and the main resource feature of subgraph b is B, calculates the confidence of A to B and B to A
Degree;
A54. the resource characteristic that confidence level is higher than confidence threshold value is filtered out, the resource characteristic filtered out is constituted into Resource Role frame
Frame.
Support threshold can be support mean value;Confidence threshold value can be confidence level mean value.
Step A6 is specifically included:
A61. the resource characteristic of Resource Role frame is ranked up according to confidence level using bubbling method, using obtained sequence as
Main decision rule;
A62. user demand relationship library conclude and form aid decision rule;
A63. decision tree is generated according to main decision rule and aid decision rule.
Aid decision rule does not influence the sequence of main decision rule, is served only for the calculating of resource requirement specific gravity.First according to master
Decision rule obtains Resource Role funnel arborescence, further according to aid decision rule computational resource requirements specific gravity, according to resource need
Specific gravity is asked to be adjusted the weight of each node resource characteristic in Resource Role funnel arborescence, to generate decision tree.