Table of Contents
Fetching ...

Classification with Costly Features in Hierarchical Deep Sets

Jaromír Janisch, Tomáš Pevný, Viliam Lisý

TL;DR

The paper extends Classification with Costly Features (CwCF) to structured, hierarchical data by integrating Hierarchical Multi-Instance Learning (HMIL) and hierarchical softmax, enabling per-sample feature acquisition within tree-like schemas. It leverages Advantage Actor-Critic ($A2C$) for training, decouples the classifier from the policy, and processes inputs with HMIL to produce embeddings used for classification and value estimation. Across seven datasets, including Threatcrowd-derived web-domain data, the approach demonstrates superior cost-efficiency by selectively obtaining informative features, often matching or exceeding full-information baselines at a fraction of the cost. The work provides extensive datasets, code, and analysis of explainability, pretraining benefits, and computational characteristics, highlighting practical impact for API-cost-aware classification in real-world streaming scenarios.

Abstract

Classification with Costly Features (CwCF) is a classification problem that includes the cost of features in the optimization criteria. Individually for each sample, its features are sequentially acquired to maximize accuracy while minimizing the acquired features' cost. However, existing approaches can only process data that can be expressed as vectors of fixed length. In real life, the data often possesses rich and complex structure, which can be more precisely described with formats such as XML or JSON. The data is hierarchical and often contains nested lists of objects. In this work, we extend an existing deep reinforcement learning-based algorithm with hierarchical deep sets and hierarchical softmax, so that it can directly process this data. The extended method has greater control over which features it can acquire and, in experiments with seven datasets, we show that this leads to superior performance. To showcase the real usage of the new method, we apply it to a real-life problem of classifying malicious web domains, using an online service.

Classification with Costly Features in Hierarchical Deep Sets

TL;DR

The paper extends Classification with Costly Features (CwCF) to structured, hierarchical data by integrating Hierarchical Multi-Instance Learning (HMIL) and hierarchical softmax, enabling per-sample feature acquisition within tree-like schemas. It leverages Advantage Actor-Critic () for training, decouples the classifier from the policy, and processes inputs with HMIL to produce embeddings used for classification and value estimation. Across seven datasets, including Threatcrowd-derived web-domain data, the approach demonstrates superior cost-efficiency by selectively obtaining informative features, often matching or exceeding full-information baselines at a fraction of the cost. The work provides extensive datasets, code, and analysis of explainability, pretraining benefits, and computational characteristics, highlighting practical impact for API-cost-aware classification in real-world streaming scenarios.

Abstract

Classification with Costly Features (CwCF) is a classification problem that includes the cost of features in the optimization criteria. Individually for each sample, its features are sequentially acquired to maximize accuracy while minimizing the acquired features' cost. However, existing approaches can only process data that can be expressed as vectors of fixed length. In real life, the data often possesses rich and complex structure, which can be more precisely described with formats such as XML or JSON. The data is hierarchical and often contains nested lists of objects. In this work, we extend an existing deep reinforcement learning-based algorithm with hierarchical deep sets and hierarchical softmax, so that it can directly process this data. The extended method has greater control over which features it can acquire and, in experiments with seven datasets, we show that this leads to superior performance. To showcase the real usage of the new method, we apply it to a real-life problem of classifying malicious web domains, using an online service.

Paper Structure

This paper contains 43 sections, 19 equations, 26 figures, 6 tables, 2 algorithms.

Figures (26)

  • Figure 1: A pruned data sample from our stats dataset, which is extracted from Stats StackExchange online service. The variable number of badges, posts, and their tags and comments means that each sample contains a different number of features. Application of existing techniques (e.g., original CwCF) would require alteration of the data. As a better alternative, we present a modified method that naturally works with the structured data and can select individual features in the hierarchy.
  • Figure 2: Illustration of the bag embedding in HMIL. Objects in the bag $\mathcal{B}$ are processed with $f_{\vartheta_\mathcal{B}}$ and aggregated. The result is used as the feature value for the parent object. The process recursively embeds the whole sample.
  • Figure 3: The schema and a partial sample for the threatcrowd dataset. (a) The schema shows the feature names, their types, and their cost in parentheses. A set type denotes that this feature contains a set of objects, whose features are described in the level below. (b) A partial sample. The full circles and lines denote features with known feature values. Among other information, the example shows that a list of domains was acquired for one of the IP addresses (46..55) with a reverse lookup.
  • Figure 4: (a) The input $\bar{x}$ is recursively processed to create embeddings $z_v$ for each object $v$ in the tree and the sample-level embedding $z_{\bar{x}}$. (c) The embedding $z_{\bar{x}}$ is used to compute class probabilities $\varrho$, value estimate $V$, and the terminal action potential $a_t$. (b) An unobserved leaf feature is chosen with a sequence of stochastic decisions. Probabilities are determined by $f_{\varphi_\mathcal{B}}(z_{\bar{x}}, z_v)$. The whole architecture is end-to-end differentiable.
  • Figure 5: Visualization of how an action is selected. Sequentially, a path is created from the root to a leaf unobserved feature (or the terminal action) by a series of stochastic decisions. In set features, all items and their features are resolved at once. The probability of the performed action is a product of the partial probabilities on the path. In this example, the chosen action $a$ selects the posts[0].comments[0].text feature with probability $\pi(a \mid \bar{x}) = \prod_{i=1}^3\varpi_i$.
  • ...and 21 more figures

Theorems & Definitions (1)

  • proof : Derivation of eq. \ref{['eq:h2']}